home *** CD-ROM | disk | FTP | other *** search
/ Ultra Pack / UltraComputing Partner Applications.iso / SunLabs / tclTK / src / tk4.0p3.patch < prev   
Text File  |  1995-11-27  |  85KB  |  2,850 lines

  1. Prereq: "4.0p2"
  2. *** ../tk4.0p2/patchlevel.h    Mon Sep 18 11:42:16 1995
  3. --- patchlevel.h    Mon Nov 27 09:03:15 1995
  4. ***************
  5. *** 17,23 ****
  6.    * See the file "license.terms" for information on usage and redistribution
  7.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  8.    *
  9. !  * @(#) patchlevel.h 1.9 95/09/18 11:42:14
  10.    */
  11.   
  12. ! #define TK_PATCH_LEVEL "4.0p2"
  13. --- 17,23 ----
  14.    * See the file "license.terms" for information on usage and redistribution
  15.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  16.    *
  17. !  * @(#) patchlevel.h 1.10 95/11/27 09:03:19
  18.    */
  19.   
  20. ! #define TK_PATCH_LEVEL "4.0p3"
  21. *** ../tk4.0p2/./Makefile.in    Mon Sep 18 13:28:27 1995
  22. --- ./Makefile.in    Mon Nov 27 13:22:35 1995
  23. ***************
  24. *** 5,11 ****
  25.   # "autoconf" program (constructs like "@foo@" will get replaced in the
  26.   # actual Makefile.
  27.   #
  28. ! # @(#) Makefile.in 1.39 95/06/30 11:18:46
  29.   
  30.   # Current Tk version;  used in various names.
  31.   
  32. --- 5,11 ----
  33.   # "autoconf" program (constructs like "@foo@" will get replaced in the
  34.   # actual Makefile.
  35.   #
  36. ! # @(#) Makefile.in 1.41 95/11/19 16:15:24
  37.   
  38.   # Current Tk version;  used in various names.
  39.   
  40. *** ../tk4.0p2/./tkBind.c    Sun Jun  4 17:37:04 1995
  41. --- ./tkBind.c    Mon Sep 25 13:19:01 1995
  42. ***************
  43. *** 11,17 ****
  44.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  45.    */
  46.   
  47. ! static char sccsid[] = "@(#) tkBind.c 1.98 95/06/04 17:37:03";
  48.   
  49.   #include "tkPort.h"
  50.   #include "tkInt.h"
  51. --- 11,17 ----
  52.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  53.    */
  54.   
  55. ! static char sccsid[] = "@(#) tkBind.c 1.100 95/09/25 13:18:59";
  56.   
  57.   #include "tkPort.h"
  58.   #include "tkInt.h"
  59. *** ../tk4.0p2/./tkColor.c    Sat Mar 18 15:43:46 1995
  60. --- ./tkColor.c    Tue Sep 26 17:11:24 1995
  61. ***************
  62. *** 12,18 ****
  63.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  64.    */
  65.   
  66. ! static char sccsid[] = "@(#) tkColor.c 1.36 95/03/18 15:43:38";
  67.   
  68.   #include "tkPort.h"
  69.   #include "tk.h"
  70. --- 12,18 ----
  71.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  72.    */
  73.   
  74. ! static char sccsid[] = "@(#) tkColor.c 1.37 95/09/26 17:11:23";
  75.   
  76.   #include "tkPort.h"
  77.   #include "tk.h"
  78. ***************
  79. *** 547,556 ****
  80.   {
  81.       TkStressedCmap *stressPtr;
  82.       float tmp, distance, closestDistance;
  83. !     int i, closest;
  84.       XColor *colorPtr;
  85.       TkDisplay *dispPtr = ((TkWindow *) tkwin)->dispPtr;
  86.       Colormap colormap = Tk_Colormap(tkwin);
  87.   
  88.       /*
  89.        * Find the TkStressedCmap structure for this colormap, or create
  90. --- 547,557 ----
  91.   {
  92.       TkStressedCmap *stressPtr;
  93.       float tmp, distance, closestDistance;
  94. !     int i, closest, numFound;
  95.       XColor *colorPtr;
  96.       TkDisplay *dispPtr = ((TkWindow *) tkwin)->dispPtr;
  97.       Colormap colormap = Tk_Colormap(tkwin);
  98. +     XVisualInfo template, *visInfoPtr;
  99.   
  100.       /*
  101.        * Find the TkStressedCmap structure for this colormap, or create
  102. ***************
  103. *** 561,567 ****
  104.       if (stressPtr == NULL) {
  105.           stressPtr = (TkStressedCmap *) ckalloc(sizeof(TkStressedCmap));
  106.           stressPtr->colormap = colormap;
  107. !         stressPtr->numColors = 1<<Tk_Depth(tkwin);
  108.           stressPtr->colorPtr = (XColor *) ckalloc((unsigned)
  109.               (stressPtr->numColors * sizeof(XColor)));
  110.           for (i = 0; i  < stressPtr->numColors; i++) {
  111. --- 562,574 ----
  112.       if (stressPtr == NULL) {
  113.           stressPtr = (TkStressedCmap *) ckalloc(sizeof(TkStressedCmap));
  114.           stressPtr->colormap = colormap;
  115. !         template.visualid = XVisualIDFromVisual(Tk_Visual(tkwin));
  116. !         visInfoPtr = XGetVisualInfo(Tk_Display(tkwin),
  117. !             VisualIDMask, &template, &numFound);
  118. !         if (numFound != 1) {
  119. !         panic("FindClosestColor couldn't lookup visual");
  120. !         }
  121. !         stressPtr->numColors = visInfoPtr->colormap_size;
  122.           stressPtr->colorPtr = (XColor *) ckalloc((unsigned)
  123.               (stressPtr->numColors * sizeof(XColor)));
  124.           for (i = 0; i  < stressPtr->numColors; i++) {
  125. *** ../tk4.0p2/./tkMain.c    Thu Jun  8 11:43:05 1995
  126. --- ./tkMain.c    Mon Sep 25 14:33:55 1995
  127. ***************
  128. *** 14,20 ****
  129.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  130.    */
  131.   
  132. ! static char sccsid[] = "@(#) tkMain.c 1.114 95/06/08 11:43:00";
  133.   
  134.   #include <ctype.h>
  135.   #include <stdio.h>
  136. --- 14,20 ----
  137.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  138.    */
  139.   
  140. ! static char sccsid[] = "@(#) tkMain.c 1.115 95/09/25 14:33:57";
  141.   
  142.   #include <ctype.h>
  143.   #include <stdio.h>
  144. ***************
  145. *** 64,69 ****
  146. --- 64,70 ----
  147.   static char *name = NULL;
  148.   static char *display = NULL;
  149.   static char *geometry = NULL;
  150. + static int rest = 0;
  151.   
  152.   static Tk_ArgvInfo argTable[] = {
  153.       {"-display", TK_ARGV_STRING, (char *) NULL, (char *) &display,
  154. ***************
  155. *** 74,79 ****
  156. --- 75,82 ----
  157.       "Name to use for application"},
  158.       {"-sync", TK_ARGV_CONSTANT, (char *) 1, (char *) &synchronize,
  159.       "Use synchronous mode for display server"},
  160. +     {"--", TK_ARGV_REST, (char *) 1, (char *) &rest,
  161. +     "Pass all remaining arguments through to script"},
  162.       {(char *) NULL, TK_ARGV_END, (char *) NULL, (char *) NULL,
  163.       (char *) NULL}
  164.   };
  165. *** ../tk4.0p2/./tkPack.c    Sun May 28 14:02:36 1995
  166. --- ./tkPack.c    Fri Nov 24 17:52:10 1995
  167. ***************
  168. *** 11,17 ****
  169.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  170.    */
  171.   
  172. ! static char sccsid[] = "@(#) tkPack.c 1.54 95/05/28 14:02:32";
  173.   
  174.   #include "tkPort.h"
  175.   #include "tkInt.h"
  176. --- 11,17 ----
  177.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  178.    */
  179.   
  180. ! static char sccsid[] = "@(#) tkPack.c 1.56 95/11/24 17:52:11";
  181.   
  182.   #include "tkPort.h"
  183.   #include "tkInt.h"
  184. ***************
  185. *** 770,776 ****
  186.           if (abort) {
  187.               goto done;
  188.           }
  189. !         Tk_MapWindow(slavePtr->tkwin);
  190.           }
  191.       } else {
  192.           if ((width <= 0) || (height <= 0)) {
  193. --- 770,784 ----
  194.           if (abort) {
  195.               goto done;
  196.           }
  197. !         /*
  198. !          * Don't map the slave if the master isn't mapped: wait
  199. !          * until the master gets mapped later.
  200. !          */
  201. !         if (Tk_IsMapped(masterPtr->tkwin)) {
  202. !             Tk_MapWindow(slavePtr->tkwin);
  203. !         }
  204.           }
  205.       } else {
  206.           if ((width <= 0) || (height <= 0)) {
  207. ***************
  208. *** 1351,1356 ****
  209. --- 1359,1388 ----
  210.       }
  211.       packPtr->tkwin = NULL;
  212.       Tk_EventuallyFree((ClientData) packPtr, DestroyPacker);
  213. +     } else if (eventPtr->type == MapNotify) {
  214. +     /*
  215. +      * When a master gets mapped, must redo the geometry computation
  216. +      * so that all of its slaves get remapped.
  217. +      */
  218. +     if ((packPtr->slavePtr != NULL)
  219. +         && !(packPtr->flags & REQUESTED_REPACK)) {
  220. +         packPtr->flags |= REQUESTED_REPACK;
  221. +         Tk_DoWhenIdle(ArrangePacking, (ClientData) packPtr);
  222. +     }
  223. +     } else if (eventPtr->type == UnmapNotify) {
  224. +     Packer *packPtr2;
  225. +     /*
  226. +      * Unmap all of the slaves when the master gets unmapped,
  227. +      * so that they don't bother to keep redisplaying
  228. +      * themselves.
  229. +      */
  230. +     for (packPtr2 = packPtr->slavePtr; packPtr2 != NULL;
  231. +         packPtr2 = packPtr2->nextPtr) {
  232. +         Tk_UnmapWindow(packPtr2->tkwin);
  233. +     }
  234.       }
  235.   }
  236.   
  237. ***************
  238. *** 1629,1635 ****
  239.   
  240.       /*
  241.        * Make sure that the slave's parent is either the master or
  242. !      * an ancestor of the master.
  243.        */
  244.       
  245.       parent = Tk_Parent(slave);
  246. --- 1661,1668 ----
  247.   
  248.       /*
  249.        * Make sure that the slave's parent is either the master or
  250. !      * an ancestor of the master, and that the master and slave
  251. !      * aren't the same.
  252.        */
  253.       
  254.       parent = Tk_Parent(slave);
  255. ***************
  256. *** 1643,1648 ****
  257. --- 1676,1686 ----
  258.               (char *) NULL);
  259.           return TCL_ERROR;
  260.           }
  261. +     }
  262. +     if (slave == masterPtr->tkwin) {
  263. +         Tcl_AppendResult(interp, "can't pack ", argv[j],
  264. +             " inside itself", (char *) NULL);
  265. +         return TCL_ERROR;
  266.       }
  267.   
  268.       /*
  269. *** ../tk4.0p2/./tkPlace.c    Sun Jun  4 14:23:52 1995
  270. --- ./tkPlace.c    Mon Nov 27 09:25:57 1995
  271. ***************
  272. *** 11,17 ****
  273.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  274.    */
  275.   
  276. ! static char sccsid[] = "@(#) tkPlace.c 1.21 95/06/04 14:23:50";
  277.   
  278.   #include "tkPort.h"
  279.   #include "tkInt.h"
  280. --- 11,17 ----
  281.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  282.    */
  283.   
  284. ! static char sccsid[] = "%Z% %M% %I% %E% %U%";
  285.   
  286.   #include "tkPort.h"
  287.   #include "tkInt.h"
  288. ***************
  289. *** 553,559 ****
  290.   
  291.           /*
  292.            * Make sure that the new master is either the logical parent
  293. !          * of the slave or a descendant of that window.
  294.            */
  295.   
  296.           for (ancestor = tkwin; ; ancestor = Tk_Parent(ancestor)) {
  297. --- 553,560 ----
  298.   
  299.           /*
  300.            * Make sure that the new master is either the logical parent
  301. !          * of the slave or a descendant of that window, and that the
  302. !          * master and slave aren't the same.
  303.            */
  304.   
  305.           for (ancestor = tkwin; ; ancestor = Tk_Parent(ancestor)) {
  306. ***************
  307. *** 568,573 ****
  308. --- 569,581 ----
  309.               goto done;
  310.           }
  311.           }
  312. +         if (slavePtr->tkwin == tkwin) {
  313. +         Tcl_AppendResult(interp, "can't place ",
  314. +             Tk_PathName(slavePtr->tkwin), " relative to itself",
  315. +             (char *) NULL);
  316. +         result = TCL_ERROR;
  317. +         goto done;
  318. +         }
  319.           if ((slavePtr->masterPtr != NULL)
  320.               && (slavePtr->masterPtr->tkwin == tkwin)) {
  321.           /*
  322. ***************
  323. *** 847,853 ****
  324.               || (height != Tk_Height(slavePtr->tkwin))) {
  325.           Tk_MoveResizeWindow(slavePtr->tkwin, x, y, width, height);
  326.           }
  327. !         Tk_MapWindow(slavePtr->tkwin);
  328.       } else {
  329.           if ((width <= 0) || (height <= 0)) {
  330.           Tk_UnmaintainGeometry(slavePtr->tkwin, masterPtr->tkwin);
  331. --- 855,869 ----
  332.               || (height != Tk_Height(slavePtr->tkwin))) {
  333.           Tk_MoveResizeWindow(slavePtr->tkwin, x, y, width, height);
  334.           }
  335. !         /*
  336. !          * Don't map the slave unless the master is mapped: the slave
  337. !          * will get mapped later, when the master is mapped.
  338. !          */
  339. !         if (Tk_IsMapped(masterPtr->tkwin)) {
  340. !         Tk_MapWindow(slavePtr->tkwin);
  341. !         }
  342.       } else {
  343.           if ((width <= 0) || (height <= 0)) {
  344.           Tk_UnmaintainGeometry(slavePtr->tkwin, masterPtr->tkwin);
  345. ***************
  346. *** 907,912 ****
  347. --- 923,949 ----
  348.       }
  349.       masterPtr->tkwin = NULL;
  350.       ckfree((char *) masterPtr);
  351. +     } else if (eventPtr->type == MapNotify) {
  352. +     /*
  353. +      * When a master gets mapped, must redo the geometry computation
  354. +      * so that all of its slaves get remapped.
  355. +      */
  356. +     if ((masterPtr->slavePtr != NULL)
  357. +         && !(masterPtr->flags & PARENT_RECONFIG_PENDING)) {
  358. +         masterPtr->flags |= PARENT_RECONFIG_PENDING;
  359. +         Tk_DoWhenIdle(RecomputePlacement, (ClientData) masterPtr);
  360. +     }
  361. +     } else if (eventPtr->type == UnmapNotify) {
  362. +     /*
  363. +      * Unmap all of the slaves when the master gets unmapped,
  364. +      * so that they don't keep redisplaying themselves.
  365. +      */
  366. +     for (slavePtr = masterPtr->slavePtr; slavePtr != NULL;
  367. +         slavePtr = slavePtr->nextPtr) {
  368. +         Tk_UnmapWindow(slavePtr->tkwin);
  369. +     }
  370.       }
  371.   }
  372.   
  373. *** ../tk4.0p2/./tkSend.c    Mon Aug 21 10:49:15 1995
  374. --- ./tkSend.c    Thu Nov  9 10:29:11 1995
  375. ***************
  376. *** 12,18 ****
  377.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  378.    */
  379.   
  380. ! static char sccsid[] = "@(#) tkSend.c 1.50 95/08/21 10:49:10";
  381.   
  382.   #include "tkPort.h"
  383.   #include "tkInt.h"
  384. --- 12,18 ----
  385.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  386.    */
  387.   
  388. ! static char sccsid[] = "@(#) tkSend.c 1.51 95/11/09 10:29:13";
  389.   
  390.   #include "tkPort.h"
  391.   #include "tkInt.h"
  392. ***************
  393. *** 1219,1226 ****
  394.                    * interpreter is needed anyway). */
  395.       TkDisplay *dispPtr;        /* Display to initialize. */
  396.   {
  397. -     TkMainInfo *mainPtr;
  398. -     TkWindow *winPtr;
  399.       XSetWindowAttributes atts;
  400.   
  401.       /*
  402. --- 1219,1224 ----
  403. ***************
  404. *** 1241,1268 ****
  405.       Tk_MakeWindowExist(dispPtr->commTkwin);
  406.   
  407.       /*
  408. -      * Find a window on the display to use for registering property
  409. -      * names.
  410. -      */
  411. -     for (mainPtr = tkMainWindowList; ; mainPtr = mainPtr->nextPtr) {
  412. -     if (mainPtr == NULL) {
  413. -         return TCL_OK;
  414. -     }
  415. -     if (mainPtr->winPtr->dispPtr == dispPtr) {
  416. -         winPtr = mainPtr->winPtr;
  417. -         break;
  418. -     }
  419. -     }
  420. -     /*
  421.        * Get atoms used as property names.
  422.        */
  423.   
  424. !     dispPtr->commProperty = Tk_InternAtom((Tk_Window) winPtr, "Comm");
  425. !     dispPtr->registryProperty = Tk_InternAtom((Tk_Window) winPtr,
  426.           "InterpRegistry");
  427. !     dispPtr->appNameProperty = Tk_InternAtom((Tk_Window) winPtr,
  428.           "TK_APPLICATION");
  429.   
  430.       return TCL_OK;
  431. --- 1239,1251 ----
  432.       Tk_MakeWindowExist(dispPtr->commTkwin);
  433.   
  434.       /*
  435.        * Get atoms used as property names.
  436.        */
  437.   
  438. !     dispPtr->commProperty = Tk_InternAtom(dispPtr->commTkwin, "Comm");
  439. !     dispPtr->registryProperty = Tk_InternAtom(dispPtr->commTkwin,
  440.           "InterpRegistry");
  441. !     dispPtr->appNameProperty = Tk_InternAtom(dispPtr->commTkwin,
  442.           "TK_APPLICATION");
  443.   
  444.       return TCL_OK;
  445. *** ../tk4.0p2/./tkVisual.c    Wed Aug 16 10:43:49 1995
  446. --- ./tkVisual.c    Sun Oct  1 16:35:39 1995
  447. ***************
  448. *** 12,18 ****
  449.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  450.    */
  451.   
  452. ! static char sccsid[] = "@(#) tkVisual.c 1.13 95/08/16 10:43:48";
  453.   
  454.   #include "tkInt.h"
  455.   #include "tkPort.h"
  456. --- 12,18 ----
  457.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  458.    */
  459.   
  460. ! static char sccsid[] = "@(#) tkVisual.c 1.14 95/10/01 16:35:38";
  461.   
  462.   #include "tkInt.h"
  463.   #include "tkPort.h"
  464. ***************
  465. *** 313,319 ****
  466.           cmapPtr->colormap = XCreateColormap(Tk_Display(tkwin),
  467.               RootWindowOfScreen(Tk_Screen(tkwin)), visual,
  468.               AllocNone);
  469. !         cmapPtr->visual = NULL;
  470.           cmapPtr->refCount = 1;
  471.           cmapPtr->shareable = 1;
  472.           cmapPtr->nextPtr = dispPtr->cmapPtr;
  473. --- 313,319 ----
  474.           cmapPtr->colormap = XCreateColormap(Tk_Display(tkwin),
  475.               RootWindowOfScreen(Tk_Screen(tkwin)), visual,
  476.               AllocNone);
  477. !         cmapPtr->visual = visual;
  478.           cmapPtr->refCount = 1;
  479.           cmapPtr->shareable = 1;
  480.           cmapPtr->nextPtr = dispPtr->cmapPtr;
  481. *** ../tk4.0p2/./tkWindow.c    Wed Jun  7 13:13:22 1995
  482. --- ./tkWindow.c    Mon Sep 25 13:19:01 1995
  483. ***************
  484. *** 13,19 ****
  485.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  486.    */
  487.   
  488. ! static char sccsid[] = "@(#) tkWindow.c 1.185 95/06/07 13:13:20";
  489.   
  490.   #include "tkPort.h"
  491.   #include "tkInt.h"
  492. --- 13,19 ----
  493.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  494.    */
  495.   
  496. ! static char sccsid[] = "@(#) tkWindow.c 1.187 95/09/25 13:18:57";
  497.   
  498.   #include "tkPort.h"
  499.   #include "tkInt.h"
  500. *** ../tk4.0p2/./tkWm.c    Mon Aug 21 10:49:16 1995
  501. --- ./tkWm.c    Mon Nov 27 13:02:34 1995
  502. ***************
  503. *** 13,19 ****
  504.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  505.    */
  506.   
  507. ! static char sccsid[] = "@(#) tkWm.c 1.108 95/08/21 10:49:12";
  508.   
  509.   #include "tkPort.h"
  510.   #include "tkInt.h"
  511. --- 13,19 ----
  512.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  513.    */
  514.   
  515. ! static char sccsid[] = "@(#) tkWm.c 1.111 95/11/27 13:02:37";
  516.   
  517.   #include "tkPort.h"
  518.   #include "tkInt.h"
  519. ***************
  520. *** 277,282 ****
  521. --- 277,284 ----
  522.   static int        ComputeReparentGeometry _ANSI_ARGS_((TkWindow *winPtr));
  523.   static void        ConfigureEvent _ANSI_ARGS_((TkWindow *winPtr,
  524.                   XConfigureEvent *eventPtr));
  525. + static void        GetMaxSize _ANSI_ARGS_((WmInfo *wmPtr,
  526. +                 int *maxWidthPtr, int *maxHeightPtr));
  527.   static int        ParseGeometry _ANSI_ARGS_((Tcl_Interp *interp,
  528.                   char *string, TkWindow *winPtr));
  529.   static void        ReparentEvent _ANSI_ARGS_((TkWindow *winPtr,
  530. ***************
  531. *** 349,356 ****
  532.        * a guess about how space is needed for window manager decorations.
  533.        */
  534.   
  535. !     wmPtr->maxWidth = DisplayWidth(winPtr->display, winPtr->screenNum) - 15;
  536. !     wmPtr->maxHeight = DisplayHeight(winPtr->display, winPtr->screenNum) - 30;
  537.       wmPtr->gridWin = NULL;
  538.       wmPtr->widthInc = wmPtr->heightInc = 1;
  539.       wmPtr->minAspect.x = wmPtr->minAspect.y = 1;
  540. --- 351,358 ----
  541.        * a guess about how space is needed for window manager decorations.
  542.        */
  543.   
  544. !     wmPtr->maxWidth = 0;
  545. !     wmPtr->maxHeight = 0;
  546.       wmPtr->gridWin = NULL;
  547.       wmPtr->widthInc = wmPtr->heightInc = 1;
  548.       wmPtr->minAspect.x = wmPtr->minAspect.y = 1;
  549. ***************
  550. *** 1348,1355 ****
  551.           return TCL_ERROR;
  552.       }
  553.       if (argc == 3) {
  554. !         sprintf(interp->result, "%d %d", wmPtr->maxWidth,
  555. !             wmPtr->maxHeight);
  556.           return TCL_OK;
  557.       }
  558.       if ((Tcl_GetInt(interp, argv[3], &width) != TCL_OK)
  559. --- 1350,1357 ----
  560.           return TCL_ERROR;
  561.       }
  562.       if (argc == 3) {
  563. !         GetMaxSize(wmPtr, &width, &height);
  564. !         sprintf(interp->result, "%d %d", width, height);
  565.           return TCL_OK;
  566.       }
  567.       if ((Tcl_GetInt(interp, argv[3], &width) != TCL_OK)
  568. ***************
  569. *** 1766,1775 ****
  570.        * in pixel units and there's no easy way to translate them to
  571.        * grid units since the new requested size of the top-level window in
  572.        * pixels may not yet have been registered yet (it may filter up
  573. !      * the hierarchy in DoWhenIdle handlers).
  574.        */
  575.   
  576. !     if (wmPtr->gridWin == NULL) {
  577.       wmPtr->width = -1;
  578.       wmPtr->height = -1;
  579.       }
  580. --- 1768,1780 ----
  581.        * in pixel units and there's no easy way to translate them to
  582.        * grid units since the new requested size of the top-level window in
  583.        * pixels may not yet have been registered yet (it may filter up
  584. !      * the hierarchy in DoWhenIdle handlers).  However, if the window
  585. !      * has never been mapped yet then just leave the window size alone:
  586. !      * assume that it is intended to be in grid units but just happened
  587. !      * to have been specified before this procedure was called.
  588.        */
  589.   
  590. !     if ((wmPtr->gridWin == NULL) && !(wmPtr->flags & WM_NEVER_MAPPED)) {
  591.       wmPtr->width = -1;
  592.       wmPtr->height = -1;
  593.       }
  594. ***************
  595. *** 2494,2499 ****
  596. --- 2499,2505 ----
  597.   {
  598.       register WmInfo *wmPtr = winPtr->wmInfoPtr;
  599.       XSizeHints *hintsPtr;
  600. +     int maxWidth, maxHeight;
  601.   
  602.       wmPtr->flags &= ~WM_UPDATE_SIZE_HINTS;
  603.   
  604. ***************
  605. *** 2508,2513 ****
  606. --- 2514,2520 ----
  607.        * our structure.
  608.        */
  609.   
  610. +     GetMaxSize(wmPtr, &maxWidth, &maxHeight);
  611.       if (wmPtr->gridWin != NULL) {
  612.       hintsPtr->base_width = winPtr->reqWidth
  613.           - (wmPtr->reqGridWidth * wmPtr->widthInc);
  614. ***************
  615. *** 2524,2537 ****
  616.       hintsPtr->min_height = hintsPtr->base_height
  617.           + (wmPtr->minHeight * wmPtr->heightInc);
  618.       hintsPtr->max_width = hintsPtr->base_width
  619. !         + (wmPtr->maxWidth * wmPtr->widthInc);
  620.       hintsPtr->max_height = hintsPtr->base_height
  621. !         + (wmPtr->maxHeight * wmPtr->heightInc);
  622.       } else {
  623.       hintsPtr->min_width = wmPtr->minWidth;
  624.       hintsPtr->min_height = wmPtr->minHeight;
  625. !     hintsPtr->max_width = wmPtr->maxWidth;
  626. !     hintsPtr->max_height = wmPtr->maxHeight;
  627.       hintsPtr->base_width = 0;
  628.       hintsPtr->base_height = 0;
  629.       }
  630. --- 2531,2544 ----
  631.       hintsPtr->min_height = hintsPtr->base_height
  632.           + (wmPtr->minHeight * wmPtr->heightInc);
  633.       hintsPtr->max_width = hintsPtr->base_width
  634. !         + (maxWidth * wmPtr->widthInc);
  635.       hintsPtr->max_height = hintsPtr->base_height
  636. !         + (maxHeight * wmPtr->heightInc);
  637.       } else {
  638.       hintsPtr->min_width = wmPtr->minWidth;
  639.       hintsPtr->min_height = wmPtr->minHeight;
  640. !     hintsPtr->max_width = maxWidth;
  641. !     hintsPtr->max_height = maxHeight;
  642.       hintsPtr->base_width = 0;
  643.       hintsPtr->base_height = 0;
  644.       }
  645. ***************
  646. *** 3756,3760 ****
  647. --- 3763,3833 ----
  648.           xPtr, yPtr, &mask) != True) {
  649.       *xPtr = -1;
  650.       *yPtr = -1;
  651. +     }
  652. + }
  653. + /*
  654. +  *----------------------------------------------------------------------
  655. +  *
  656. +  * GetMaxSize --
  657. +  *
  658. +  *    This procedure computes the current maxWidth and maxHeight
  659. +  *    values for a window, taking into account the possibility
  660. +  *    that they may be defaulted.
  661. +  *
  662. +  * Results:
  663. +  *    The values at *maxWidthPtr and *maxHeightPtr are filled
  664. +  *    in with the maximum allowable dimensions of wmPtr's window,
  665. +  *    in grid units.  If no maximum has been specified for the
  666. +  *    window, then this procedure computes the largest sizes that
  667. +  *    will fit on the screen.
  668. +  *
  669. +  * Side effects:
  670. +  *    None.
  671. +  *
  672. +  *----------------------------------------------------------------------
  673. +  */
  674. + static void
  675. + GetMaxSize(wmPtr, maxWidthPtr, maxHeightPtr)
  676. +     WmInfo *wmPtr;        /* Window manager information for the
  677. +                  * window. */
  678. +     int *maxWidthPtr;        /* Where to store the current maximum
  679. +                  * width of the window. */
  680. +     int *maxHeightPtr;        /* Where to store the current maximum
  681. +                  * height of the window. */
  682. + {
  683. +     int tmp;
  684. +     if (wmPtr->maxWidth > 0) {
  685. +     *maxWidthPtr = wmPtr->maxWidth;
  686. +     } else {
  687. +     /*
  688. +      * Must compute a default width.  Fill up the display, leaving a
  689. +      * bit of extra space for the window manager's borders.
  690. +      */
  691. +     tmp = DisplayWidth(wmPtr->winPtr->display, wmPtr->winPtr->screenNum)
  692. +         - 15;
  693. +     if (wmPtr->gridWin != NULL) {
  694. +         /*
  695. +          * Gridding is turned on;  convert from pixels to grid units.
  696. +          */
  697. +         tmp = wmPtr->reqGridWidth
  698. +             + (tmp - wmPtr->winPtr->reqWidth)/wmPtr->widthInc;
  699. +     }
  700. +     *maxWidthPtr = tmp;
  701. +     }
  702. +     if (wmPtr->maxHeight > 0) {
  703. +     *maxHeightPtr = wmPtr->maxHeight;
  704. +     } else {
  705. +     tmp = DisplayHeight(wmPtr->winPtr->display, wmPtr->winPtr->screenNum)
  706. +         - 30;
  707. +     if (wmPtr->gridWin != NULL) {
  708. +         tmp = wmPtr->reqGridHeight
  709. +             + (tmp - wmPtr->winPtr->reqHeight)/wmPtr->heightInc;
  710. +     }
  711. +     *maxHeightPtr = tmp;
  712.       }
  713.   }
  714. *** ../tk4.0p2/./tkButton.c    Sat Jul 22 16:05:26 1995
  715. --- ./tkButton.c    Mon Sep 25 14:56:28 1995
  716. ***************
  717. *** 13,19 ****
  718.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  719.    */
  720.   
  721. ! static char sccsid[] = "@(#) tkButton.c 1.120 95/07/22 16:05:25";
  722.   
  723.   #include "default.h"
  724.   #include "tkPort.h"
  725. --- 13,19 ----
  726.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  727.    */
  728.   
  729. ! static char sccsid[] = "@(#) tkButton.c 1.121 95/09/25 14:56:29";
  730.   
  731.   #include "default.h"
  732.   #include "tkPort.h"
  733. ***************
  734. *** 1311,1319 ****
  735.           y += butPtr->borderWidth;
  736.           dim -= 2*butPtr->borderWidth;
  737.           if (butPtr->flags & SELECTED) {
  738. !         XFillRectangle(butPtr->display, pixmap, Tk_3DBorderGC(tkwin,
  739. !             butPtr->selectBorder, TK_3D_FLAT_GC),
  740. !             x, y, (unsigned int) dim, (unsigned int) dim);
  741.           } else {
  742.           Tk_Fill3DRectangle(tkwin, pixmap, butPtr->normalBorder, x, y,
  743.               dim, dim, butPtr->borderWidth, TK_RELIEF_FLAT);
  744. --- 1311,1323 ----
  745.           y += butPtr->borderWidth;
  746.           dim -= 2*butPtr->borderWidth;
  747.           if (butPtr->flags & SELECTED) {
  748. !         GC gc;
  749. !         gc = Tk_3DBorderGC(tkwin,(butPtr->selectBorder != NULL)
  750. !             ? butPtr->selectBorder : butPtr->normalBorder,
  751. !             TK_3D_FLAT_GC);
  752. !         XFillRectangle(butPtr->display, pixmap, gc, x, y,
  753. !             (unsigned int) dim, (unsigned int) dim);
  754.           } else {
  755.           Tk_Fill3DRectangle(tkwin, pixmap, butPtr->normalBorder, x, y,
  756.               dim, dim, butPtr->borderWidth, TK_RELIEF_FLAT);
  757. ***************
  758. *** 1333,1341 ****
  759.       points[3].x = points[1].x;
  760.       points[3].y = points[0].y - radius;
  761.       if (butPtr->flags & SELECTED) {
  762. !         XFillPolygon(butPtr->display, pixmap,
  763. !             Tk_3DBorderGC(tkwin, butPtr->selectBorder, TK_3D_FLAT_GC),
  764. !             points, 4, Convex, CoordModeOrigin);
  765.       } else {
  766.           Tk_Fill3DPolygon(tkwin, pixmap, butPtr->normalBorder, points,
  767.               4, butPtr->borderWidth, TK_RELIEF_FLAT);
  768. --- 1337,1349 ----
  769.       points[3].x = points[1].x;
  770.       points[3].y = points[0].y - radius;
  771.       if (butPtr->flags & SELECTED) {
  772. !         GC gc;
  773. !         gc = Tk_3DBorderGC(tkwin, (butPtr->selectBorder != NULL)
  774. !             ? butPtr->selectBorder : butPtr->normalBorder,
  775. !             TK_3D_FLAT_GC);
  776. !         XFillPolygon(butPtr->display, pixmap, gc, points, 4, Convex,
  777. !             CoordModeOrigin);
  778.       } else {
  779.           Tk_Fill3DPolygon(tkwin, pixmap, butPtr->normalBorder, points,
  780.               4, butPtr->borderWidth, TK_RELIEF_FLAT);
  781. *** ../tk4.0p2/./tkEntry.c    Sun May 28 17:50:03 1995
  782. --- ./tkEntry.c    Tue Sep 26 13:33:15 1995
  783. ***************
  784. *** 12,18 ****
  785.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  786.    */
  787.   
  788. ! static char sccsid[] = "@(#) tkEntry.c 1.90 95/05/28 17:49:57";
  789.   
  790.   #include "default.h"
  791.   #include "tkPort.h"
  792. --- 12,18 ----
  793.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  794.    */
  795.   
  796. ! static char sccsid[] = "@(#) tkEntry.c 1.91 95/09/26 13:33:13";
  797.   
  798.   #include "default.h"
  799.   #include "tkPort.h"
  800. ***************
  801. *** 299,304 ****
  802. --- 299,305 ----
  803.                   Tcl_Interp *interp, char *name1, char *name2,
  804.                   int flags));
  805.   static void        EntryUpdateScrollbar _ANSI_ARGS_((Entry *entryPtr));
  806. + static void        EntryValueChanged _ANSI_ARGS_((Entry *entryPtr));
  807.   static void        EntryVisibleRange _ANSI_ARGS_((Entry *entryPtr,
  808.                   double *firstPtr, double *lastPtr));
  809.   static int        EntryWidgetCmd _ANSI_ARGS_((ClientData clientData,
  810. ***************
  811. *** 863,870 ****
  812.   
  813.       value = Tcl_GetVar(interp, entryPtr->textVarName, TCL_GLOBAL_ONLY);
  814.       if (value == NULL) {
  815. !         Tcl_SetVar(interp, entryPtr->textVarName, entryPtr->string,
  816. !             TCL_GLOBAL_ONLY);
  817.       } else {
  818.           EntrySetValue(entryPtr, value);
  819.       }
  820. --- 864,870 ----
  821.   
  822.       value = Tcl_GetVar(interp, entryPtr->textVarName, TCL_GLOBAL_ONLY);
  823.       if (value == NULL) {
  824. !         EntryValueChanged(entryPtr);
  825.       } else {
  826.           EntrySetValue(entryPtr, value);
  827.       }
  828. ***************
  829. *** 1334,1347 ****
  830.       if (entryPtr->insertPos >= index) {
  831.       entryPtr->insertPos += length;
  832.       }
  833. !     if (entryPtr->textVarName != NULL) {
  834. !     Tcl_SetVar(entryPtr->interp, entryPtr->textVarName, entryPtr->string,
  835. !         TCL_GLOBAL_ONLY);
  836. !     }
  837. !     entryPtr->flags |= UPDATE_SCROLLBAR;
  838. !     EntryComputeGeometry(entryPtr);
  839. !     EventuallyRedraw(entryPtr);
  840.   }
  841.   
  842.   /*
  843. --- 1334,1340 ----
  844.       if (entryPtr->insertPos >= index) {
  845.       entryPtr->insertPos += length;
  846.       }
  847. !     EntryValueChanged(entryPtr);
  848.   }
  849.   
  850.   /*
  851. ***************
  852. *** 1427,1440 ****
  853.           entryPtr->insertPos = index;
  854.       }
  855.       }
  856.   
  857. !     if (entryPtr->textVarName != NULL) {
  858. !     Tcl_SetVar(entryPtr->interp, entryPtr->textVarName, entryPtr->string,
  859. !         TCL_GLOBAL_ONLY);
  860.       }
  861. !     entryPtr->flags |= UPDATE_SCROLLBAR;
  862. !     EntryComputeGeometry(entryPtr);
  863. !     EventuallyRedraw(entryPtr);
  864.   }
  865.   
  866.   /*
  867. --- 1420,1479 ----
  868.           entryPtr->insertPos = index;
  869.       }
  870.       }
  871. +     EntryValueChanged(entryPtr);
  872. + }
  873. + /*
  874. +  *----------------------------------------------------------------------
  875. +  *
  876. +  * EntryValueChanged --
  877. +  *
  878. +  *    This procedure is invoked when characters are inserted into
  879. +  *    an entry or deleted from it.  It updates the entry's associated
  880. +  *    variable, if there is one, and does other bookkeeping such
  881. +  *    as arranging for redisplay.
  882. +  *
  883. +  * Results:
  884. +  *    None.
  885. +  *
  886. +  * Side effects:
  887. +  *    None.
  888. +  *
  889. +  *----------------------------------------------------------------------
  890. +  */
  891.   
  892. ! static void
  893. ! EntryValueChanged(entryPtr)
  894. !     Entry *entryPtr;        /* Entry whose value just changed. */
  895. ! {
  896. !     char *newValue;
  897. !     if (entryPtr->textVarName == NULL) {
  898. !     newValue = NULL;
  899. !     } else {
  900. !     newValue = Tcl_SetVar(entryPtr->interp, entryPtr->textVarName,
  901. !         entryPtr->string, TCL_GLOBAL_ONLY);
  902.       }
  903. !     if ((newValue != NULL) && (strcmp(newValue, entryPtr->string) != 0)) {
  904. !     /*
  905. !      * The value of the variable is different than what we asked for.
  906. !      * This means that a trace on the variable modified it.  In this
  907. !      * case our trace procedure wasn't invoked since the modification
  908. !      * came while a trace was already active on the variable.  So,
  909. !      * update our value to reflect the variable's latest value.
  910. !      */
  911. !     EntrySetValue(entryPtr, newValue);
  912. !     } else {
  913. !     /*
  914. !      * Arrange for redisplay.
  915. !      */
  916. !     entryPtr->flags |= UPDATE_SCROLLBAR;
  917. !     EntryComputeGeometry(entryPtr);
  918. !     EventuallyRedraw(entryPtr);
  919. !     }
  920.   }
  921.   
  922.   /*
  923. *** ../tk4.0p2/./tkListbox.c    Tue Jul 25 12:50:15 1995
  924. --- ./tkListbox.c    Tue Sep 26 16:18:24 1995
  925. ***************
  926. *** 12,18 ****
  927.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  928.    */
  929.   
  930. ! static char sccsid[] = "@(#) tkListbox.c 1.97 95/07/25 12:50:13";
  931.   
  932.   #include "tkPort.h"
  933.   #include "default.h"
  934. --- 12,18 ----
  935.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  936.    */
  937.   
  938. ! static char sccsid[] = "@(#) tkListbox.c 1.99 95/09/26 16:18:22";
  939.   
  940.   #include "tkPort.h"
  941.   #include "default.h"
  942. ***************
  943. *** 790,796 ****
  944.           case TK_SCROLL_ERROR:
  945.               goto error;
  946.           case TK_SCROLL_MOVETO:
  947. !             offset = fraction*listPtr->maxWidth;
  948.               break;
  949.           case TK_SCROLL_PAGES:
  950.               windowUnits = windowWidth/listPtr->xScrollUnit;
  951. --- 790,796 ----
  952.           case TK_SCROLL_ERROR:
  953.               goto error;
  954.           case TK_SCROLL_MOVETO:
  955. !             offset = fraction*listPtr->maxWidth + 0.5;
  956.               break;
  957.           case TK_SCROLL_PAGES:
  958.               windowUnits = windowWidth/listPtr->xScrollUnit;
  959. ***************
  960. *** 835,841 ****
  961.           case TK_SCROLL_ERROR:
  962.               goto error;
  963.           case TK_SCROLL_MOVETO:
  964. !             index = listPtr->numElements*fraction;
  965.               break;
  966.           case TK_SCROLL_PAGES:
  967.               if (listPtr->fullLines > 2) {
  968. --- 835,841 ----
  969.           case TK_SCROLL_ERROR:
  970.               goto error;
  971.           case TK_SCROLL_MOVETO:
  972. !             index = listPtr->numElements*fraction + 0.5;
  973.               break;
  974.           case TK_SCROLL_PAGES:
  975.               if (listPtr->fullLines > 2) {
  976. *** ../tk4.0p2/./tkMenubutton.c    Fri Jun  9 08:20:08 1995
  977. --- ./tkMenubutton.c    Sun Nov 19 16:06:56 1995
  978. ***************
  979. *** 11,17 ****
  980.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  981.    */
  982.   
  983. ! static char sccsid[] = "@(#) tkMenubutton.c 1.70 95/06/09 08:20:02";
  984.   
  985.   #include "tkPort.h"
  986.   #include "default.h"
  987. --- 11,17 ----
  988.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  989.    */
  990.   
  991. ! static char sccsid[] = "@(#) tkMenubutton.c 1.71 95/11/19 16:06:57";
  992.   
  993.   #include "tkPort.h"
  994.   #include "default.h"
  995. ***************
  996. *** 636,642 ****
  997.   
  998.       gcValues.font = mbPtr->fontPtr->fid;
  999.       gcValues.background = Tk_3DBorderColor(mbPtr->normalBorder)->pixel;
  1000. !     if (mbPtr->disabledFg != NULL) {
  1001.       gcValues.foreground = mbPtr->disabledFg->pixel;
  1002.       mask = GCForeground|GCBackground|GCFont;
  1003.       } else {
  1004. --- 636,642 ----
  1005.   
  1006.       gcValues.font = mbPtr->fontPtr->fid;
  1007.       gcValues.background = Tk_3DBorderColor(mbPtr->normalBorder)->pixel;
  1008. !     if ((mbPtr->disabledFg != NULL) && (mbPtr->imageString == NULL)) {
  1009.       gcValues.foreground = mbPtr->disabledFg->pixel;
  1010.       mask = GCForeground|GCBackground|GCFont;
  1011.       } else {
  1012. ***************
  1013. *** 889,895 ****
  1014.        * foreground color, generate the stippled effect.
  1015.        */
  1016.   
  1017. !     if ((mbPtr->state == tkDisabledUid) && (mbPtr->disabledFg == NULL)) {
  1018.       XFillRectangle(mbPtr->display, pixmap, mbPtr->disabledGC,
  1019.           mbPtr->inset, mbPtr->inset,
  1020.           (unsigned) (Tk_Width(tkwin) - 2*mbPtr->inset),
  1021. --- 889,896 ----
  1022.        * foreground color, generate the stippled effect.
  1023.        */
  1024.   
  1025. !     if ((mbPtr->state == tkDisabledUid)
  1026. !         && ((mbPtr->disabledFg == NULL) || (mbPtr->image != NULL))) {
  1027.       XFillRectangle(mbPtr->display, pixmap, mbPtr->disabledGC,
  1028.           mbPtr->inset, mbPtr->inset,
  1029.           (unsigned) (Tk_Width(tkwin) - 2*mbPtr->inset),
  1030. *** ../tk4.0p2/./tkScale.c    Fri Jun  9 08:20:08 1995
  1031. --- ./tkScale.c    Sat Nov 25 22:47:14 1995
  1032. ***************
  1033. *** 18,24 ****
  1034.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1035.    */
  1036.   
  1037. ! static char sccsid[] = "@(#) tkScale.c 1.72 95/06/09 08:20:04";
  1038.   
  1039.   #include "tkPort.h"
  1040.   #include "default.h"
  1041. --- 18,24 ----
  1042.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1043.    */
  1044.   
  1045. ! static char sccsid[] = "@(#) tkScale.c 1.73 95/11/25 22:47:16";
  1046.   
  1047.   #include "tkPort.h"
  1048.   #include "default.h"
  1049. ***************
  1050. *** 722,728 ****
  1051.       if (stringValue != NULL) {
  1052.           value = strtod(stringValue, &end);
  1053.           if ((end != stringValue) && (*end == 0)) {
  1054. !         scalePtr->value = value;
  1055.           }
  1056.       }
  1057.       Tcl_TraceVar(interp, scalePtr->varName,
  1058. --- 722,728 ----
  1059.       if (stringValue != NULL) {
  1060.           value = strtod(stringValue, &end);
  1061.           if ((end != stringValue) && (*end == 0)) {
  1062. !         scalePtr->value = RoundToResolution(scalePtr, value);
  1063.           }
  1064.       }
  1065.       Tcl_TraceVar(interp, scalePtr->varName,
  1066. ***************
  1067. *** 1953,1972 ****
  1068.       Scale *scalePtr;        /* Information about scale widget. */
  1069.       double value;        /* Value to round. */
  1070.   {
  1071. !     double rem;
  1072.   
  1073.       if (scalePtr->resolution <= 0) {
  1074.       return value;
  1075.       }
  1076. !     rem = fmod(value, scalePtr->resolution);
  1077.       if (rem < 0) {
  1078. !     rem = scalePtr->resolution + rem;
  1079.       }
  1080. !     value -= rem;
  1081. !     if (rem >= scalePtr->resolution/2) {
  1082. !     value += scalePtr->resolution;
  1083. !     }
  1084. !     return value;
  1085.   }
  1086.   
  1087.   /*
  1088. --- 1953,1975 ----
  1089.       Scale *scalePtr;        /* Information about scale widget. */
  1090.       double value;        /* Value to round. */
  1091.   {
  1092. !     double rem, new;
  1093.   
  1094.       if (scalePtr->resolution <= 0) {
  1095.       return value;
  1096.       }
  1097. !     new = scalePtr->resolution * floor(value/scalePtr->resolution);
  1098. !     rem = value - new;
  1099.       if (rem < 0) {
  1100. !     if (rem <= -scalePtr->resolution/2) {
  1101. !         new -= scalePtr->resolution;
  1102. !     }
  1103. !     } else {
  1104. !     if (rem >= scalePtr->resolution/2) {
  1105. !         new += scalePtr->resolution;
  1106. !     }
  1107.       }
  1108. !     return new;
  1109.   }
  1110.   
  1111.   /*
  1112. ***************
  1113. *** 2033,2039 ****
  1114.       if ((end == stringValue) || (*end != 0)) {
  1115.           result = "can't assign non-numeric value to scale variable";
  1116.       } else {
  1117. !         scalePtr->value = value;
  1118.       }
  1119.   
  1120.       /*
  1121. --- 2036,2042 ----
  1122.       if ((end == stringValue) || (*end != 0)) {
  1123.           result = "can't assign non-numeric value to scale variable";
  1124.       } else {
  1125. !         scalePtr->value = RoundToResolution(scalePtr, value);
  1126.       }
  1127.   
  1128.       /*
  1129. *** ../tk4.0p2/./tkCanvas.c    Wed Aug 16 09:42:14 1995
  1130. --- ./tkCanvas.c    Fri Nov 24 15:46:15 1995
  1131. ***************
  1132. *** 12,18 ****
  1133.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1134.    */
  1135.   
  1136. ! static char sccsid[] = "@(#) tkCanvas.c 1.103 95/08/16 09:42:13";
  1137.   
  1138.   #include "default.h"
  1139.   #include "tkInt.h"
  1140. --- 12,18 ----
  1141.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1142.    */
  1143.   
  1144. ! static char sccsid[] = "@(#) tkCanvas.c 1.104 95/11/24 15:46:15";
  1145.   
  1146.   #include "default.h"
  1147.   #include "tkInt.h"
  1148. ***************
  1149. *** 2873,2879 ****
  1150.    * Side effects:
  1151.    *    The current item for canvasPtr may change.  If it does,
  1152.    *    then the commands associated with item entry and exit
  1153. !  *    could do just about anything.
  1154.    *
  1155.    *--------------------------------------------------------------
  1156.    */
  1157. --- 2873,2881 ----
  1158.    * Side effects:
  1159.    *    The current item for canvasPtr may change.  If it does,
  1160.    *    then the commands associated with item entry and exit
  1161. !  *    could do just about anything.  A binding script could
  1162. !  *    delete the canvas, so callers should protect themselves
  1163. !  *    with Tk_Preserve and Tk_Release.
  1164.    *
  1165.    *--------------------------------------------------------------
  1166.    */
  1167. ***************
  1168. *** 3109,3115 ****
  1169.    *    None.
  1170.    *
  1171.    * Side effects:
  1172. !  *    Depends on the bindings for the canvas.
  1173.    *
  1174.    *--------------------------------------------------------------
  1175.    */
  1176. --- 3111,3119 ----
  1177.    *    None.
  1178.    *
  1179.    * Side effects:
  1180. !  *    Depends on the bindings for the canvas.  A binding script
  1181. !  *    could delete the canvas, so callers should protect themselves
  1182. !  *    with Tk_Preserve and Tk_Release.
  1183.    *
  1184.    *--------------------------------------------------------------
  1185.    */
  1186. ***************
  1187. *** 3165,3172 ****
  1188.        * it was malloc-ed.
  1189.        */
  1190.   
  1191. !     Tk_BindEvent(canvasPtr->bindingTable, eventPtr, canvasPtr->tkwin,
  1192. !         numObjects, objectPtr);
  1193.       if (objectPtr != staticObjects) {
  1194.       ckfree((char *) objectPtr);
  1195.       }
  1196. --- 3169,3178 ----
  1197.        * it was malloc-ed.
  1198.        */
  1199.   
  1200. !     if (canvasPtr->tkwin != NULL) {
  1201. !     Tk_BindEvent(canvasPtr->bindingTable, eventPtr, canvasPtr->tkwin,
  1202. !         numObjects, objectPtr);
  1203. !     }
  1204.       if (objectPtr != staticObjects) {
  1205.       ckfree((char *) objectPtr);
  1206.       }
  1207. *** ../tk4.0p2/./tkCanvLine.c    Fri Jun  9 09:46:57 1995
  1208. --- ./tkCanvLine.c    Wed Oct 11 14:07:17 1995
  1209. ***************
  1210. *** 10,16 ****
  1211.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1212.    */
  1213.   
  1214. ! static char sccsid[] = "@(#) tkCanvLine.c 1.35 95/06/09 09:46:54";
  1215.   
  1216.   #include <stdio.h>
  1217.   #include "tkInt.h"
  1218. --- 10,16 ----
  1219.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1220.    */
  1221.   
  1222. ! static char sccsid[] = "@(#) tkCanvLine.c 1.36 95/10/11 14:07:14";
  1223.   
  1224.   #include <stdio.h>
  1225.   #include "tkInt.h"
  1226. ***************
  1227. *** 813,819 ****
  1228.                    * had to be treated as beveled after all
  1229.                    * because the angle was < 11 degrees. */
  1230.   
  1231. !     bestDist = 1.0e40;
  1232.   
  1233.       /*
  1234.        * Handle smoothed lines by generating an expanded set of points
  1235. --- 813,819 ----
  1236.                    * had to be treated as beveled after all
  1237.                    * because the angle was < 11 degrees. */
  1238.   
  1239. !     bestDist = 1.0e36;
  1240.   
  1241.       /*
  1242.        * Handle smoothed lines by generating an expanded set of points
  1243. *** ../tk4.0p2/./tkCanvPs.c    Fri Aug  4 10:05:09 1995
  1244. --- ./tkCanvPs.c    Thu Nov  9 11:34:10 1995
  1245. ***************
  1246. *** 12,18 ****
  1247.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1248.    */
  1249.   
  1250. ! static char sccsid[] = "@(#) tkCanvPs.c 1.36 95/08/04 10:05:08";
  1251.   
  1252.   #include <stdio.h>
  1253.   #include "tkInt.h"
  1254. --- 12,18 ----
  1255.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1256.    */
  1257.   
  1258. ! static char sccsid[] = "@(#) tkCanvPs.c 1.37 95/11/09 11:34:12";
  1259.   
  1260.   #include <stdio.h>
  1261.   #include "tkInt.h"
  1262. ***************
  1263. *** 722,728 ****
  1264.           }
  1265.           sprintf(pointString, "%.15g", size);
  1266.           Tcl_AppendResult(interp, "/", argv[0], " findfont ",
  1267. !             pointString, " scalefont setfont\n", (char *) NULL);
  1268.           Tcl_CreateHashEntry(&psInfoPtr->fontTable, argv[0], &i);
  1269.           ckfree((char *) argv);
  1270.           return TCL_OK;
  1271. --- 722,732 ----
  1272.           }
  1273.           sprintf(pointString, "%.15g", size);
  1274.           Tcl_AppendResult(interp, "/", argv[0], " findfont ",
  1275. !             pointString, " scalefont ", (char *) NULL);
  1276. !         if (strncasecmp(argv[0], "Symbol", 7) != 0) {
  1277. !         Tcl_AppendResult(interp, "ISOEncode ", (char *) NULL);
  1278. !         }
  1279. !         Tcl_AppendResult(interp, "setfont\n", (char *) NULL);
  1280.           Tcl_CreateHashEntry(&psInfoPtr->fontTable, argv[0], &i);
  1281.           ckfree((char *) argv);
  1282.           return TCL_OK;
  1283. ***************
  1284. *** 814,820 ****
  1285.       }
  1286.       sprintf(pointString, "%.15g", ((double) points)/10.0);
  1287.       Tcl_AppendResult(interp, "/", fontName, " findfont ",
  1288. !         pointString, " scalefont setfont\n", (char *) NULL);
  1289.       Tcl_CreateHashEntry(&psInfoPtr->fontTable, fontName, &i);
  1290.       return TCL_OK;
  1291.   
  1292. --- 818,828 ----
  1293.       }
  1294.       sprintf(pointString, "%.15g", ((double) points)/10.0);
  1295.       Tcl_AppendResult(interp, "/", fontName, " findfont ",
  1296. !         pointString, " scalefont ", (char *) NULL);
  1297. !     if (strcmp(fontName, "Symbol ") != 0) {
  1298. !     Tcl_AppendResult(interp, "ISOEncode ", (char *) NULL);
  1299. !     }
  1300. !     Tcl_AppendResult(interp, "setfont\n", (char *) NULL);
  1301.       Tcl_CreateHashEntry(&psInfoPtr->fontTable, fontName, &i);
  1302.       return TCL_OK;
  1303.   
  1304. *** ../tk4.0p2/./tkRectOval.c    Thu Mar 16 08:34:03 1995
  1305. --- ./tkRectOval.c    Sun Oct  1 16:28:51 1995
  1306. ***************
  1307. *** 11,17 ****
  1308.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1309.    */
  1310.   
  1311. ! static char sccsid[] = "@(#) tkRectOval.c 1.31 95/01/03 17:06:03";
  1312.   
  1313.   #include <stdio.h>
  1314.   #include "tk.h"
  1315. --- 11,17 ----
  1316.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1317.    */
  1318.   
  1319. ! static char sccsid[] = "@(#) tkRectOval.c 1.32 95/10/01 16:28:50";
  1320.   
  1321.   #include <stdio.h>
  1322.   #include "tk.h"
  1323. ***************
  1324. *** 455,462 ****
  1325.       } else {
  1326.       bloat = (rectOvalPtr->width+1)/2;
  1327.       }
  1328. !     rectOvalPtr->header.x1 = rectOvalPtr->bbox[0] - bloat;
  1329. !     rectOvalPtr->header.y1 = rectOvalPtr->bbox[1] - bloat;
  1330.       rectOvalPtr->header.x2 = rectOvalPtr->bbox[2] + bloat + 1;
  1331.       rectOvalPtr->header.y2 = rectOvalPtr->bbox[3] + bloat + 1;
  1332.   }
  1333. --- 455,469 ----
  1334.       } else {
  1335.       bloat = (rectOvalPtr->width+1)/2;
  1336.       }
  1337. !     /*
  1338. !      * Note:  add an extra pixel to the bounding box on all sides to
  1339. !      * account for rounding error (e.g. negative coords will be rounded
  1340. !      * differently than positive ones).
  1341. !      */
  1342. !     rectOvalPtr->header.x1 = rectOvalPtr->bbox[0] - bloat - 1;
  1343. !     rectOvalPtr->header.y1 = rectOvalPtr->bbox[1] - bloat - 1;
  1344.       rectOvalPtr->header.x2 = rectOvalPtr->bbox[2] + bloat + 1;
  1345.       rectOvalPtr->header.y2 = rectOvalPtr->bbox[3] + bloat + 1;
  1346.   }
  1347. *** ../tk4.0p2/./tkTrig.c    Fri Jun  9 09:46:57 1995
  1348. --- ./tkTrig.c    Wed Oct 11 14:07:17 1995
  1349. ***************
  1350. *** 13,19 ****
  1351.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1352.    */
  1353.   
  1354. ! static char sccsid[] = "@(#) tkTrig.c 1.21 95/06/09 09:46:57";
  1355.   
  1356.   #include <stdio.h>
  1357.   #include "tkInt.h"
  1358. --- 13,19 ----
  1359.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1360.    */
  1361.   
  1362. ! static char sccsid[] = "@(#) tkTrig.c 1.22 95/10/11 14:07:16";
  1363.   
  1364.   #include <stdio.h>
  1365.   #include "tkInt.h"
  1366. ***************
  1367. *** 465,471 ****
  1368.        * count it as two intersections.
  1369.        */
  1370.   
  1371. !     bestDist = 1.0e40;
  1372.       intersections = 0;
  1373.   
  1374.       for (count = numPoints, pPtr = polyPtr; count > 1; count--, pPtr += 2) {
  1375. --- 465,471 ----
  1376.        * count it as two intersections.
  1377.        */
  1378.   
  1379. !     bestDist = 1.0e36;
  1380.       intersections = 0;
  1381.   
  1382.       for (count = numPoints, pPtr = polyPtr; count > 1; count--, pPtr += 2) {
  1383. *** ../tk4.0p2/./tkTextDisp.c    Sat Jul 22 17:17:20 1995
  1384. --- ./tkTextDisp.c    Tue Nov 21 13:15:26 1995
  1385. ***************
  1386. *** 12,18 ****
  1387.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1388.    */
  1389.   
  1390. ! static char sccsid[] = "@(#) tkTextDisp.c 1.92 95/07/22 17:17:18";
  1391.   
  1392.   #include "tkPort.h"
  1393.   #include "tkInt.h"
  1394. --- 12,18 ----
  1395.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1396.    */
  1397.   
  1398. ! static char sccsid[] = "@(#) tkTextDisp.c 1.96 95/11/21 13:15:27";
  1399.   
  1400.   #include "tkPort.h"
  1401.   #include "tkInt.h"
  1402. ***************
  1403. *** 747,752 ****
  1404. --- 747,756 ----
  1405.                        * style for first character on line. */
  1406.       int tabSize;            /* Number of pixels consumed by current
  1407.                        * tab stop. */
  1408. +     TkTextDispChunk *lastCharChunkPtr;    /* Pointer to last chunk in display
  1409. +                      * lines with numChars > 0.  Used to
  1410. +                      * drop 0-sized chunks from the end
  1411. +                      * of the line. */
  1412.       int offset, ascent, descent, code;
  1413.       StyleValues *sValuePtr;
  1414.   
  1415. ***************
  1416. *** 785,790 ****
  1417. --- 789,795 ----
  1418.       rMargin = 0;
  1419.       wrapMode = tkTextCharUid;
  1420.       tabSize = 0;
  1421. +     lastCharChunkPtr = NULL;
  1422.   
  1423.       /*
  1424.        * Find the first segment to consider for the line.  Can't call
  1425. ***************
  1426. *** 885,890 ****
  1427. --- 890,896 ----
  1428.       }
  1429.       if (chunkPtr->numChars > 0) {
  1430.           noCharsYet = 0;
  1431. +         lastCharChunkPtr = chunkPtr;
  1432.       }
  1433.       if (lastChunkPtr == NULL) {
  1434.           dlPtr->chunkPtr = chunkPtr;
  1435. ***************
  1436. *** 940,945 ****
  1437. --- 946,963 ----
  1438.        * potentially require the last chunk to be layed out again.
  1439.        */
  1440.   
  1441. +     if (breakChunkPtr == NULL) {
  1442. +     /*
  1443. +      * This code makes sure that we don't accidentally display
  1444. +      * chunks with no characters at the end of the line (such as
  1445. +      * the insertion cursor).  These chunks belong on the next
  1446. +      * line.  So, throw away everything after the last chunk that
  1447. +      * has characters in it.
  1448. +      */
  1449. +     breakChunkPtr = lastCharChunkPtr;
  1450. +     breakCharOffset = breakChunkPtr->numChars;
  1451. +     }
  1452.       if ((breakChunkPtr != NULL) && ((lastChunkPtr != breakChunkPtr)
  1453.           || (breakCharOffset != lastChunkPtr->numChars))) {
  1454.       while (1) {
  1455. ***************
  1456. *** 1198,1203 ****
  1457. --- 1216,1226 ----
  1458.           newPtr = dlPtr->nextPtr;
  1459.           FreeDLines(textPtr, dlPtr, newPtr, 0);
  1460.           dlPtr = newPtr;
  1461. +         if (prevPtr != NULL) {
  1462. +         prevPtr->nextPtr = newPtr;
  1463. +         } else {
  1464. +         dInfoPtr->dLinePtr = newPtr;
  1465. +         }
  1466.           continue;
  1467.       }
  1468.   
  1469. ***************
  1470. *** 2759,2765 ****
  1471.   {
  1472.       DInfo *dInfoPtr = textPtr->dInfoPtr;
  1473.       register DLine *dlPtr;
  1474. !     int bottomY, close, lineIndex;
  1475.       TkTextIndex tmpIndex, rounded;
  1476.   
  1477.       /*
  1478. --- 2782,2788 ----
  1479.   {
  1480.       DInfo *dInfoPtr = textPtr->dInfoPtr;
  1481.       register DLine *dlPtr;
  1482. !     int bottomY, close, lineIndex, lineHeight;
  1483.       TkTextIndex tmpIndex, rounded;
  1484.   
  1485.       /*
  1486. ***************
  1487. *** 2815,2825 ****
  1488.       }
  1489.   
  1490.       /*
  1491. !      * The desired line isn't already on-screen.
  1492.        */
  1493.   
  1494. !     bottomY = (dInfoPtr->y + dInfoPtr->maxY)/2;
  1495.       close = (dInfoPtr->maxY - dInfoPtr->y)/3;
  1496.       if (dlPtr != NULL) {
  1497.       /*
  1498.        * The desired line is above the top of screen.  If it is
  1499. --- 2838,2857 ----
  1500.       }
  1501.   
  1502.       /*
  1503. !      * The desired line isn't already on-screen.  Figure out what
  1504. !      * it means to be "close" to the top or bottom of the screen.
  1505. !      * Close means within 1/3 of the screen height or within three
  1506. !      * lines, whichever is greater.  Add one extra line also, to
  1507. !      * account for the way MeasureUp rounds.
  1508.        */
  1509.   
  1510. !     lineHeight = textPtr->fontPtr->ascent + textPtr->fontPtr->descent;
  1511. !     bottomY = (dInfoPtr->y + dInfoPtr->maxY + lineHeight)/2;
  1512.       close = (dInfoPtr->maxY - dInfoPtr->y)/3;
  1513. +     if (close < 3*lineHeight) {
  1514. +     close = 3*lineHeight;
  1515. +     }
  1516. +     close += lineHeight;
  1517.       if (dlPtr != NULL) {
  1518.       /*
  1519.        * The desired line is above the top of screen.  If it is
  1520. ***************
  1521. *** 2850,2856 ****
  1522.        * as low on the screen as possible but with its bottom no lower
  1523.        * than bottomY.  BottomY is the bottom of the window if the
  1524.        * desired line is just below the current screen, otherwise it
  1525. !      * is the center of the window.
  1526.        */
  1527.   
  1528.       MeasureUp(textPtr, indexPtr, bottomY, &textPtr->topIndex);
  1529. --- 2882,2888 ----
  1530.        * as low on the screen as possible but with its bottom no lower
  1531.        * than bottomY.  BottomY is the bottom of the window if the
  1532.        * desired line is just below the current screen, otherwise it
  1533. !      * is a half-line lower than the center of the window.
  1534.        */
  1535.   
  1536.       MeasureUp(textPtr, indexPtr, bottomY, &textPtr->topIndex);
  1537. ***************
  1538. *** 3133,3139 ****
  1539.       case TK_SCROLL_ERROR:
  1540.           return TCL_ERROR;
  1541.       case TK_SCROLL_MOVETO:
  1542. !         newOffset = (fraction * dInfoPtr->maxLength) / textPtr->charWidth;
  1543.           break;
  1544.       case TK_SCROLL_PAGES:
  1545.           charsPerPage = ((dInfoPtr->maxX - dInfoPtr->x) / textPtr->charWidth)
  1546. --- 3165,3178 ----
  1547.       case TK_SCROLL_ERROR:
  1548.           return TCL_ERROR;
  1549.       case TK_SCROLL_MOVETO:
  1550. !         if (fraction > 1.0) {
  1551. !         fraction = 1.0;
  1552. !         }
  1553. !         if (fraction < 0) {
  1554. !         fraction = 0;
  1555. !         }
  1556. !           newOffset = ((fraction * dInfoPtr->maxLength) / textPtr->charWidth)
  1557. !             + 0.5;
  1558.           break;
  1559.       case TK_SCROLL_PAGES:
  1560.           charsPerPage = ((dInfoPtr->maxX - dInfoPtr->x) / textPtr->charWidth)
  1561. ***************
  1562. *** 3359,3374 ****
  1563.       case TK_SCROLL_ERROR:
  1564.           return TCL_ERROR;
  1565.       case TK_SCROLL_MOVETO:
  1566.           fraction *= TkBTreeNumLines(textPtr->tree);
  1567.           lineNum = fraction;
  1568. !         TkTextMakeIndex(textPtr->tree, lineNum+1, 0, &index);
  1569. !         TkTextIndexBackChars(&index, 1, &index);
  1570. !         index.charIndex = (index.charIndex+1)*(fraction-lineNum);
  1571.           TkTextSetYView(textPtr, &index, 0);
  1572.           break;
  1573.       case TK_SCROLL_PAGES:
  1574.           /*
  1575. !          * Scroll up or down by screenfulls.  Actually, use the
  1576.            * window height minus two lines, so that there's some
  1577.            * overlap between adjacent pages.
  1578.            */
  1579. --- 3398,3419 ----
  1580.       case TK_SCROLL_ERROR:
  1581.           return TCL_ERROR;
  1582.       case TK_SCROLL_MOVETO:
  1583. +         if (fraction > 1.0) {
  1584. +         fraction = 1.0;
  1585. +         }
  1586. +         if (fraction < 0) {
  1587. +         fraction = 0;
  1588. +         }
  1589.           fraction *= TkBTreeNumLines(textPtr->tree);
  1590.           lineNum = fraction;
  1591. !         TkTextMakeIndex(textPtr->tree, lineNum, 0, &index);
  1592. !         index.charIndex = TkBTreeCharsInLine(index.linePtr)
  1593. !             * (fraction-lineNum) + 0.5;
  1594.           TkTextSetYView(textPtr, &index, 0);
  1595.           break;
  1596.       case TK_SCROLL_PAGES:
  1597.           /*
  1598. !          * Scroll up or down by screenfuls.  Actually, use the
  1599.            * window height minus two lines, so that there's some
  1600.            * overlap between adjacent pages.
  1601.            */
  1602. *** ../tk4.0p2/./tkTextTag.c    Thu May 25 10:36:16 1995
  1603. --- ./tkTextTag.c    Fri Nov 24 15:46:16 1995
  1604. ***************
  1605. *** 12,18 ****
  1606.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1607.    */
  1608.   
  1609. ! static char sccsid[] = "@(#) tkTextTag.c 1.28 95/05/25 10:36:17";
  1610.   
  1611.   #include "default.h"
  1612.   #include "tkPort.h"
  1613. --- 12,18 ----
  1614.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1615.    */
  1616.   
  1617. ! static char sccsid[] = "@(#) tkTextTag.c 1.29 95/11/24 15:46:17";
  1618.   
  1619.   #include "default.h"
  1620.   #include "tkPort.h"
  1621. ***************
  1622. *** 1108,1114 ****
  1623.       }
  1624.       TkTextPickCurrent(textPtr, eventPtr);
  1625.       }
  1626. !     if ((textPtr->numCurTags > 0) && (textPtr->bindingTable != NULL)) {
  1627.       Tk_BindEvent(textPtr->bindingTable, eventPtr, textPtr->tkwin,
  1628.           textPtr->numCurTags, (ClientData *) textPtr->curTagArrayPtr);
  1629.       }
  1630. --- 1108,1115 ----
  1631.       }
  1632.       TkTextPickCurrent(textPtr, eventPtr);
  1633.       }
  1634. !     if ((textPtr->numCurTags > 0) && (textPtr->bindingTable != NULL)
  1635. !         && (textPtr->tkwin != NULL)) {
  1636.       Tk_BindEvent(textPtr->bindingTable, eventPtr, textPtr->tkwin,
  1637.           textPtr->numCurTags, (ClientData *) textPtr->curTagArrayPtr);
  1638.       }
  1639. ***************
  1640. *** 1143,1149 ****
  1641.    * Side effects:
  1642.    *    The current mark for textPtr may change.  If it does,
  1643.    *    then the commands associated with character entry and leave
  1644. !  *    could do just about anything.
  1645.    *
  1646.    *--------------------------------------------------------------
  1647.    */
  1648. --- 1144,1152 ----
  1649.    * Side effects:
  1650.    *    The current mark for textPtr may change.  If it does,
  1651.    *    then the commands associated with character entry and leave
  1652. !  *    could do just about anything.  For example, the text widget
  1653. !  *    might be deleted.  It is up to the caller to protect itself
  1654. !  *    with calls to Tk_Preserve and Tk_Release.
  1655.    *
  1656.    *--------------------------------------------------------------
  1657.    */
  1658. ***************
  1659. *** 1278,1284 ****
  1660.       oldArrayPtr = textPtr->curTagArrayPtr;
  1661.       textPtr->curTagArrayPtr = newArrayPtr;
  1662.       if (numOldTags != 0) {
  1663. !     if (textPtr->bindingTable != NULL) {
  1664.           event = textPtr->pickEvent;
  1665.           event.type = LeaveNotify;
  1666.   
  1667. --- 1281,1287 ----
  1668.       oldArrayPtr = textPtr->curTagArrayPtr;
  1669.       textPtr->curTagArrayPtr = newArrayPtr;
  1670.       if (numOldTags != 0) {
  1671. !     if ((textPtr->bindingTable != NULL) && (textPtr->tkwin != NULL)) {
  1672.           event = textPtr->pickEvent;
  1673.           event.type = LeaveNotify;
  1674.   
  1675. ***************
  1676. *** 1306,1312 ****
  1677.           textPtr->pickEvent.xcrossing.y, &index);
  1678.       TkTextSetMark(textPtr, "current", &index);
  1679.       if (numNewTags != 0) {
  1680. !     if (textPtr->bindingTable != NULL) {
  1681.           event = textPtr->pickEvent;
  1682.           event.type = EnterNotify;
  1683.           event.xcrossing.detail = NotifyAncestor;
  1684. --- 1309,1315 ----
  1685.           textPtr->pickEvent.xcrossing.y, &index);
  1686.       TkTextSetMark(textPtr, "current", &index);
  1687.       if (numNewTags != 0) {
  1688. !     if ((textPtr->bindingTable != NULL) && (textPtr->tkwin != NULL)) {
  1689.           event = textPtr->pickEvent;
  1690.           event.type = EnterNotify;
  1691.           event.xcrossing.detail = NotifyAncestor;
  1692. *** ../tk4.0p2/./tkInt.h    Sat Jun 24 17:12:55 1995
  1693. --- ./tkInt.h    Mon Sep 25 13:19:01 1995
  1694. ***************
  1695. *** 10,16 ****
  1696.    * See the file "license.terms" for information on usage and redistribution
  1697.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1698.    *
  1699. !  * @(#) tkInt.h 1.147 95/06/24 17:12:55
  1700.    */
  1701.   
  1702.   #ifndef _TKINT
  1703. --- 10,16 ----
  1704.    * See the file "license.terms" for information on usage and redistribution
  1705.    * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  1706.    *
  1707. !  * @(#) tkInt.h 1.149 95/09/25 13:19:00
  1708.    */
  1709.   
  1710.   #ifndef _TKINT
  1711. *** ../tk4.0p2/./changes    Mon Sep 18 13:27:53 1995
  1712. --- ./changes    Mon Nov 27 09:02:16 1995
  1713. ***************
  1714. *** 2,8 ****
  1715.   released on March 13, 1991.  Changes that aren't backward compatible
  1716.   are marked specially.
  1717.   
  1718. ! sccsid = @(#) changes 1.23 95/09/18 13:27:50
  1719.   
  1720.   3/16/91 (bug fix) Modified tkWindow.c to remove Tk's Tcl commands from
  1721.   the interpreter when the main window is deleted (otherwise there will
  1722. --- 2,8 ----
  1723.   released on March 13, 1991.  Changes that aren't backward compatible
  1724.   are marked specially.
  1725.   
  1726. ! sccsid = @(#) changes 1.26 95/11/27 09:02:19
  1727.   
  1728.   3/16/91 (bug fix) Modified tkWindow.c to remove Tk's Tcl commands from
  1729.   the interpreter when the main window is deleted (otherwise there will
  1730. ***************
  1731. *** 2506,2511 ****
  1732.   could occasionally happen in tkScaleDrag. (JO)
  1733.   
  1734.   9/19/95 (bug fix) Fixed bug in text index processing that causes
  1735. ! tests textIndex-11.1 and textIndex12.1 to fail on some platforms.
  1736.   
  1737.   ----------------- Released patch 4.0p2, 9/19/95 ----------------------
  1738. --- 2506,2624 ----
  1739.   could occasionally happen in tkScaleDrag. (JO)
  1740.   
  1741.   9/19/95 (bug fix) Fixed bug in text index processing that causes
  1742. ! tests textIndex-11.1 and textIndex12.1 to fail on some platforms. (JO)
  1743.   
  1744.   ----------------- Released patch 4.0p2, 9/19/95 ----------------------
  1745. + 9/22/95 (bug fix) Fixed bug where text widgets could occasionally
  1746. + display the insertion cursor both at the end of one line and the
  1747. + beginning of the next. (JO)
  1748. + 9/25/95 (bug fix) Text widgets sometimes scrolled backwards on
  1749. + occasion if you dragged down past the bottom of the scrollbar. (JO)
  1750. + 9/25/95 (bug fix) Fixed bug in menus where a cascaded submenu posted
  1751. + from a torn-off menu could be left posted if mouse was pulled off the
  1752. + end of the cascade and released. (JO)
  1753. + 9/25/95 (new feature) Added "--" switch to wish, so that you can
  1754. + pass arguments like -n through to a script without having wish
  1755. + interpret them. (JO)
  1756. + 9/25/95 (bug fix) Fixed core dump that could occur for radiobuttons
  1757. + and selectbuttons if -selectcolor was an empty string. (JO)
  1758. + 9/26/95 (bug fix) Entries didn't used to notice if a trace procedure
  1759. + on the -textvariable overrode a new value set by the entry.  This
  1760. + could cause the variable to get out of sync with the contents of the
  1761. + entry. (JO)
  1762. + 9/26/95 (bug fix) Fixed round-off errors in listbox scrolling.  Among
  1763. + other things, this could cause listbox view to shift slightly at
  1764. + unexpected times. (JO)
  1765. + 9/26/95 (bug fix) TkColor.c wasn't computing colormap size correctly;
  1766. + could result in X Protocol error for QueryColors when colormaps run
  1767. + out of colors. (JO)
  1768. + 9/27/95 (feature change)  Modified tk_dialog so that it uses the
  1769. + option database for the -wraplength option on the message.  This
  1770. + allows the option to be overridden by the caller. (JO)
  1771. + 10/1/95 (bug fix) Canvas rectangles weren't computing their bounding
  1772. + boxes correctly when coordinates were negative, resulting in improper
  1773. + redisplay (e.g. junk left behind) when dragging. (JO)
  1774. + 10/30/95 (bug fix) When focus-follows-mode (invoked via tk_focusFollowsMouse),
  1775. + was focussing on windows even in situations where keyboard traversal would
  1776. + skip the window.  Changed to use the tkFocusOK procedure so that the
  1777. + criteria for focussing are the same in both modes. (JO)
  1778. + 11/2/95 (bug fix) Changed listbox bindings to ignore double-clicks.
  1779. + This avoids errors that used to occur if a user defined a binding
  1780. + for double-click that deleted the listbox. (JO)
  1781. + 11/7/95 (bug fix) If wish was invoked with a command-line geometry and
  1782. + a script file (e.g. "wish foo.tcl -geometry 30x20"), and if one of
  1783. + the windows created by the script used the -setgrid option, then the
  1784. + width and height from the command line were lost. (JO)
  1785. + 11/8/95 (bug fix) The "see" command didn't work quite right for texts:
  1786. + if the window was small and you try to "see" a line just offscreen,
  1787. + Tk centered the line (actually, mis-centered it) when it should have
  1788. + aligned it at the top or bottom. (JO)
  1789. + 11/9/95 (bug fix) The "send" command crashed if you tried to send to
  1790. + a different display with "-displayof". (JO)
  1791. + 11/9/95 (bug fix) The Symbol font didn't print right in Postscript
  1792. + output, because of changes made to re-encode fonts to get proper
  1793. + ISO Latin1 behavior.  Changed the code not to re-encode the Symbol
  1794. + font. (JO)
  1795. + 11/17/95 (bug fix) If a window was gridded, Tk still computed the
  1796. + default maximum dimensions in pixel units, which resulted in windows
  1797. + that could grow much larger than the screen. (JO)
  1798. + 11/17/95 (bug fix) If a menus entries were all disabled, posting
  1799. + the menu and typing Up or Down caused an infinite loop, locking
  1800. + up the screen (JO).
  1801. + 11/19/95 (bug fix) The focus wasn't being restored properly after a
  1802. + menu selection in a cascaded menu. (JO)
  1803. + 11/19/95 (bug fix) Menubutton's didn't stipple display their images
  1804. + differently when disabled.  Change to have the same behavior as buttons:
  1805. + the image is stippled over in the background color when the menubutton
  1806. + is disabled. (JO)
  1807. + 11/21/95 (bug fix) Changes in display attributes such as font could
  1808. + cause core dumps in the text widget under some circumstances involving
  1809. + line wrapping. (JO)
  1810. + 11/22/95 (bug fix/new feature)  Changed both the placer and the packer
  1811. + to ensure that slaves are unmapped whenever the master is unmapped.
  1812. + This saves time that slaves might otherwise spend trying to redisplay
  1813. + themselves when they're unmapped. (JO)
  1814. + 11/22/95 (bug fix) Space and return keys didn't work for menus if
  1815. + they were posted via Alt-x keystrokes. (JO)
  1816. + 11/24/95 (bug fix) tk_dialog procedure had binding for <Return> that
  1817. + always activated default binding, even if input focus was in some
  1818. + other binding.  Removed this feature, since existing focus support
  1819. + will already "do the right thing".  (JO)
  1820. + 11/24/95 (bug fix) Both canvases and texts could dump core if a binding
  1821. + (such as ButtonRelease on an internal item) deleted the widget. (JO)
  1822. + 11/24/95 (bug fix) It was possible for a slave to be placed or packed
  1823. + -in itself, with unpleasant consequences.  It is now an error for the
  1824. + slave to be its own master for geometry management. (JO)
  1825. + 11/25/95 (bug fix) The -command option of scales was sometimes being
  1826. + invoked spuriously (e.g. when the mouse moved in the scale without a
  1827. + button down).  This was because the scale wasn't rounding properly
  1828. + when setting the scale value from its associated variable. (JO)
  1829. + ----------------- Released patch 4.0p3, 11/28/95 ----------------------
  1830. *** ../tk4.0p2/./configure    Mon Sep 18 11:08:13 1995
  1831. --- ./configure    Mon Nov 27 09:04:23 1995
  1832. ***************
  1833. *** 401,407 ****
  1834.   
  1835.   
  1836.   
  1837. ! # @(#) configure.in 1.18 95/09/05 17:04:17
  1838.   
  1839.   ac_aux_dir=
  1840.   for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
  1841. --- 401,407 ----
  1842.   
  1843.   
  1844.   
  1845. ! # @(#) configure.in 1.19 95/10/11 14:13:45
  1846.   
  1847.   ac_aux_dir=
  1848.   for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
  1849. ***************
  1850. *** 1259,1264 ****
  1851. --- 1259,1265 ----
  1852.           for i in $dirs ; do
  1853.           if test -r $i/X11/Intrinsic.h; then
  1854.               XINCLUDES=" -I$i"
  1855. +         break
  1856.           fi
  1857.           done
  1858.       fi
  1859. ***************
  1860. *** 1282,1287 ****
  1861. --- 1283,1289 ----
  1862.       for i in $dirs ; do
  1863.           if test -r $i/libX11.a; then
  1864.           XLIBSW="-L$i -lX11"
  1865. +         break
  1866.           fi
  1867.       done
  1868.       fi
  1869. ***************
  1870. *** 1300,1306 ****
  1871.     ac_save_LIBS="$LIBS"
  1872.   LIBS="-lXwindow  $LIBS"
  1873.   cat > conftest.$ac_ext <<EOF
  1874. ! #line 1304 "configure"
  1875.   #include "confdefs.h"
  1876.   
  1877.   int main() { return 0; }
  1878. --- 1302,1308 ----
  1879.     ac_save_LIBS="$LIBS"
  1880.   LIBS="-lXwindow  $LIBS"
  1881.   cat > conftest.$ac_ext <<EOF
  1882. ! #line 1306 "configure"
  1883.   #include "confdefs.h"
  1884.   
  1885.   int main() { return 0; }
  1886. ***************
  1887. *** 1358,1364 ****
  1888.     ac_save_LIBS="$LIBS"
  1889.   LIBS="-lXbsd  $LIBS"
  1890.   cat > conftest.$ac_ext <<EOF
  1891. ! #line 1362 "configure"
  1892.   #include "confdefs.h"
  1893.   
  1894.   int main() { return 0; }
  1895. --- 1360,1366 ----
  1896.     ac_save_LIBS="$LIBS"
  1897.   LIBS="-lXbsd  $LIBS"
  1898.   cat > conftest.$ac_ext <<EOF
  1899. ! #line 1364 "configure"
  1900.   #include "confdefs.h"
  1901.   
  1902.   int main() { return 0; }
  1903. ***************
  1904. *** 1391,1397 ****
  1905.     echo $ac_n "(cached) $ac_c" 1>&6
  1906.   else
  1907.     cat > conftest.$ac_ext <<EOF
  1908. ! #line 1395 "configure"
  1909.   #include "confdefs.h"
  1910.   /* System header to define __stub macros and hopefully few prototypes,
  1911.       which can conflict with char connect(); below.  */
  1912. --- 1393,1399 ----
  1913.     echo $ac_n "(cached) $ac_c" 1>&6
  1914.   else
  1915.     cat > conftest.$ac_ext <<EOF
  1916. ! #line 1397 "configure"
  1917.   #include "confdefs.h"
  1918.   /* System header to define __stub macros and hopefully few prototypes,
  1919.       which can conflict with char connect(); below.  */
  1920. ***************
  1921. *** 1439,1445 ****
  1922.     ac_save_LIBS="$LIBS"
  1923.   LIBS="-lsocket  $LIBS"
  1924.   cat > conftest.$ac_ext <<EOF
  1925. ! #line 1443 "configure"
  1926.   #include "confdefs.h"
  1927.   
  1928.   int main() { return 0; }
  1929. --- 1441,1447 ----
  1930.     ac_save_LIBS="$LIBS"
  1931.   LIBS="-lsocket  $LIBS"
  1932.   cat > conftest.$ac_ext <<EOF
  1933. ! #line 1445 "configure"
  1934.   #include "confdefs.h"
  1935.   
  1936.   int main() { return 0; }
  1937. ***************
  1938. *** 1475,1481 ****
  1939.     echo $ac_n "(cached) $ac_c" 1>&6
  1940.   else
  1941.     cat > conftest.$ac_ext <<EOF
  1942. ! #line 1479 "configure"
  1943.   #include "confdefs.h"
  1944.   /* System header to define __stub macros and hopefully few prototypes,
  1945.       which can conflict with char accept(); below.  */
  1946. --- 1477,1483 ----
  1947.     echo $ac_n "(cached) $ac_c" 1>&6
  1948.   else
  1949.     cat > conftest.$ac_ext <<EOF
  1950. ! #line 1481 "configure"
  1951.   #include "confdefs.h"
  1952.   /* System header to define __stub macros and hopefully few prototypes,
  1953.       which can conflict with char accept(); below.  */
  1954. ***************
  1955. *** 1521,1527 ****
  1956.     echo $ac_n "(cached) $ac_c" 1>&6
  1957.   else
  1958.     cat > conftest.$ac_ext <<EOF
  1959. ! #line 1525 "configure"
  1960.   #include "confdefs.h"
  1961.   /* System header to define __stub macros and hopefully few prototypes,
  1962.       which can conflict with char gethostbyname(); below.  */
  1963. --- 1523,1529 ----
  1964.     echo $ac_n "(cached) $ac_c" 1>&6
  1965.   else
  1966.     cat > conftest.$ac_ext <<EOF
  1967. ! #line 1527 "configure"
  1968.   #include "confdefs.h"
  1969.   /* System header to define __stub macros and hopefully few prototypes,
  1970.       which can conflict with char gethostbyname(); below.  */
  1971. ***************
  1972. *** 1565,1571 ****
  1973.     ac_save_LIBS="$LIBS"
  1974.   LIBS="-lnsl  $LIBS"
  1975.   cat > conftest.$ac_ext <<EOF
  1976. ! #line 1569 "configure"
  1977.   #include "confdefs.h"
  1978.   
  1979.   int main() { return 0; }
  1980. --- 1567,1573 ----
  1981.     ac_save_LIBS="$LIBS"
  1982.   LIBS="-lnsl  $LIBS"
  1983.   cat > conftest.$ac_ext <<EOF
  1984. ! #line 1571 "configure"
  1985.   #include "confdefs.h"
  1986.   
  1987.   int main() { return 0; }
  1988. ***************
  1989. *** 1612,1618 ****
  1990.       tk_oldLibs=$LIBS
  1991.       LIBS="$LIBS -lX11-mit"
  1992.       cat > conftest.$ac_ext <<EOF
  1993. ! #line 1616 "configure"
  1994.   #include "confdefs.h"
  1995.   
  1996.       #include <X11/Xlib.h>
  1997. --- 1614,1620 ----
  1998.       tk_oldLibs=$LIBS
  1999.       LIBS="$LIBS -lX11-mit"
  2000.       cat > conftest.$ac_ext <<EOF
  2001. ! #line 1618 "configure"
  2002.   #include "confdefs.h"
  2003.   
  2004.       #include <X11/Xlib.h>
  2005. ***************
  2006. *** 1654,1660 ****
  2007.   
  2008.   echo $ac_n "checking count field in FILE structures""... $ac_c" 1>&6
  2009.   cat > conftest.$ac_ext <<EOF
  2010. ! #line 1658 "configure"
  2011.   #include "confdefs.h"
  2012.   #include <stdio.h>
  2013.   int main() { return 0; }
  2014. --- 1656,1662 ----
  2015.   
  2016.   echo $ac_n "checking count field in FILE structures""... $ac_c" 1>&6
  2017.   cat > conftest.$ac_ext <<EOF
  2018. ! #line 1660 "configure"
  2019.   #include "confdefs.h"
  2020.   #include <stdio.h>
  2021.   int main() { return 0; }
  2022. ***************
  2023. *** 1670,1676 ****
  2024.   
  2025.   if test "$fcnt" = ""; then
  2026.       cat > conftest.$ac_ext <<EOF
  2027. ! #line 1674 "configure"
  2028.   #include "confdefs.h"
  2029.   #include <stdio.h>
  2030.   int main() { return 0; }
  2031. --- 1672,1678 ----
  2032.   
  2033.   if test "$fcnt" = ""; then
  2034.       cat > conftest.$ac_ext <<EOF
  2035. ! #line 1676 "configure"
  2036.   #include "confdefs.h"
  2037.   #include <stdio.h>
  2038.   int main() { return 0; }
  2039. ***************
  2040. *** 1687,1693 ****
  2041.   fi
  2042.   if test "$fcnt" = ""; then
  2043.       cat > conftest.$ac_ext <<EOF
  2044. ! #line 1691 "configure"
  2045.   #include "confdefs.h"
  2046.   #include <stdio.h>
  2047.   int main() { return 0; }
  2048. --- 1689,1695 ----
  2049.   fi
  2050.   if test "$fcnt" = ""; then
  2051.       cat > conftest.$ac_ext <<EOF
  2052. ! #line 1693 "configure"
  2053.   #include "confdefs.h"
  2054.   #include <stdio.h>
  2055.   int main() { return 0; }
  2056. ***************
  2057. *** 1704,1710 ****
  2058.   fi
  2059.   if test "$fcnt" = ""; then
  2060.       cat > conftest.$ac_ext <<EOF
  2061. ! #line 1708 "configure"
  2062.   #include "confdefs.h"
  2063.   #include <stdio.h>
  2064.   int main() { return 0; }
  2065. --- 1706,1712 ----
  2066.   fi
  2067.   if test "$fcnt" = ""; then
  2068.       cat > conftest.$ac_ext <<EOF
  2069. ! #line 1710 "configure"
  2070.   #include "confdefs.h"
  2071.   #include <stdio.h>
  2072.   int main() { return 0; }
  2073. ***************
  2074. *** 1727,1733 ****
  2075.   fi
  2076.   if test "$fcnt" = ""; then
  2077.       cat > conftest.$ac_ext <<EOF
  2078. ! #line 1731 "configure"
  2079.   #include "confdefs.h"
  2080.   #include <stdio.h>
  2081.   int main() { return 0; }
  2082. --- 1729,1735 ----
  2083.   fi
  2084.   if test "$fcnt" = ""; then
  2085.       cat > conftest.$ac_ext <<EOF
  2086. ! #line 1733 "configure"
  2087.   #include "confdefs.h"
  2088.   #include <stdio.h>
  2089.   int main() { return 0; }
  2090. ***************
  2091. *** 1754,1760 ****
  2092.   fi
  2093.   if test "$fcnt" = ""; then
  2094.       cat > conftest.$ac_ext <<EOF
  2095. ! #line 1758 "configure"
  2096.   #include "confdefs.h"
  2097.   #include <stdio.h>
  2098.   int main() { return 0; }
  2099. --- 1756,1762 ----
  2100.   fi
  2101.   if test "$fcnt" = ""; then
  2102.       cat > conftest.$ac_ext <<EOF
  2103. ! #line 1760 "configure"
  2104.   #include "confdefs.h"
  2105.   #include <stdio.h>
  2106.   int main() { return 0; }
  2107. ***************
  2108. *** 1798,1804 ****
  2109.     echo $ac_n "(cached) $ac_c" 1>&6
  2110.   else
  2111.     cat > conftest.$ac_ext <<EOF
  2112. ! #line 1802 "configure"
  2113.   #include "confdefs.h"
  2114.   /* System header to define __stub macros and hopefully few prototypes,
  2115.       which can conflict with char sin(); below.  */
  2116. --- 1800,1806 ----
  2117.     echo $ac_n "(cached) $ac_c" 1>&6
  2118.   else
  2119.     cat > conftest.$ac_ext <<EOF
  2120. ! #line 1804 "configure"
  2121.   #include "confdefs.h"
  2122.   /* System header to define __stub macros and hopefully few prototypes,
  2123.       which can conflict with char sin(); below.  */
  2124. ***************
  2125. *** 1845,1851 ****
  2126.     ac_save_LIBS="$LIBS"
  2127.   LIBS="-lieee  $LIBS"
  2128.   cat > conftest.$ac_ext <<EOF
  2129. ! #line 1849 "configure"
  2130.   #include "confdefs.h"
  2131.   
  2132.   int main() { return 0; }
  2133. --- 1847,1853 ----
  2134.     ac_save_LIBS="$LIBS"
  2135.   LIBS="-lieee  $LIBS"
  2136.   cat > conftest.$ac_ext <<EOF
  2137. ! #line 1851 "configure"
  2138.   #include "confdefs.h"
  2139.   
  2140.   int main() { return 0; }
  2141. ***************
  2142. *** 1883,1889 ****
  2143.     echo $ac_n "(cached) $ac_c" 1>&6
  2144.   else
  2145.     cat > conftest.$ac_ext <<EOF
  2146. ! #line 1887 "configure"
  2147.   #include "confdefs.h"
  2148.   /* System header to define __stub macros and hopefully few prototypes,
  2149.       which can conflict with char memmove(); below.  */
  2150. --- 1885,1891 ----
  2151.     echo $ac_n "(cached) $ac_c" 1>&6
  2152.   else
  2153.     cat > conftest.$ac_ext <<EOF
  2154. ! #line 1889 "configure"
  2155.   #include "confdefs.h"
  2156.   /* System header to define __stub macros and hopefully few prototypes,
  2157.       which can conflict with char memmove(); below.  */
  2158. ***************
  2159. *** 1937,1943 ****
  2160.       { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
  2161.   else
  2162.   cat > conftest.$ac_ext <<EOF
  2163. ! #line 1941 "configure"
  2164.   #include "confdefs.h"
  2165.   
  2166.   int main()
  2167. --- 1939,1945 ----
  2168.       { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
  2169.   else
  2170.   cat > conftest.$ac_ext <<EOF
  2171. ! #line 1943 "configure"
  2172.   #include "confdefs.h"
  2173.   
  2174.   int main()
  2175. ***************
  2176. *** 1983,1989 ****
  2177.     echo $ac_n "(cached) $ac_c" 1>&6
  2178.   else
  2179.     cat > conftest.$ac_ext <<EOF
  2180. ! #line 1987 "configure"
  2181.   #include "confdefs.h"
  2182.   /* System header to define __stub macros and hopefully few prototypes,
  2183.       which can conflict with char BSDgettimeofday(); below.  */
  2184. --- 1985,1991 ----
  2185.     echo $ac_n "(cached) $ac_c" 1>&6
  2186.   else
  2187.     cat > conftest.$ac_ext <<EOF
  2188. ! #line 1989 "configure"
  2189.   #include "confdefs.h"
  2190.   /* System header to define __stub macros and hopefully few prototypes,
  2191.       which can conflict with char BSDgettimeofday(); below.  */
  2192. ***************
  2193. *** 2027,2033 ****
  2194.   
  2195.   echo $ac_n "checking for gettimeofday declaration""... $ac_c" 1>&6
  2196.   cat > conftest.$ac_ext <<EOF
  2197. ! #line 2031 "configure"
  2198.   #include "confdefs.h"
  2199.   #include <sys/time.h>
  2200.   EOF
  2201. --- 2029,2035 ----
  2202.   
  2203.   echo $ac_n "checking for gettimeofday declaration""... $ac_c" 1>&6
  2204.   cat > conftest.$ac_ext <<EOF
  2205. ! #line 2033 "configure"
  2206.   #include "confdefs.h"
  2207.   #include <sys/time.h>
  2208.   EOF
  2209. ***************
  2210. *** 2060,2066 ****
  2211.     echo $ac_n "(cached) $ac_c" 1>&6
  2212.   else
  2213.     cat > conftest.$ac_ext <<EOF
  2214. ! #line 2064 "configure"
  2215.   #include "confdefs.h"
  2216.   /* System header to define __stub macros and hopefully few prototypes,
  2217.       which can conflict with char strtod(); below.  */
  2218. --- 2062,2068 ----
  2219.     echo $ac_n "(cached) $ac_c" 1>&6
  2220.   else
  2221.     cat > conftest.$ac_ext <<EOF
  2222. ! #line 2066 "configure"
  2223.   #include "confdefs.h"
  2224.   /* System header to define __stub macros and hopefully few prototypes,
  2225.       which can conflict with char strtod(); below.  */
  2226. ***************
  2227. *** 2106,2112 ****
  2228.       { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
  2229.   else
  2230.   cat > conftest.$ac_ext <<EOF
  2231. ! #line 2110 "configure"
  2232.   #include "confdefs.h"
  2233.   
  2234.       extern double strtod();
  2235. --- 2108,2114 ----
  2236.       { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
  2237.   else
  2238.   cat > conftest.$ac_ext <<EOF
  2239. ! #line 2112 "configure"
  2240.   #include "confdefs.h"
  2241.   
  2242.       extern double strtod();
  2243. *** ../tk4.0p2/./configure.in    Tue Sep  5 17:04:17 1995
  2244. --- ./configure.in    Wed Oct 11 14:13:44 1995
  2245. ***************
  2246. *** 3,9 ****
  2247.   dnl    to configure the system for the local environment.
  2248.   AC_INIT(tk.h)
  2249.   
  2250. ! # @(#) configure.in 1.18 95/09/05 17:04:17
  2251.   
  2252.   AC_PROG_INSTALL
  2253.   AC_PROG_RANLIB
  2254. --- 3,9 ----
  2255.   dnl    to configure the system for the local environment.
  2256.   AC_INIT(tk.h)
  2257.   
  2258. ! # @(#) configure.in 1.19 95/10/11 14:13:45
  2259.   
  2260.   AC_PROG_INSTALL
  2261.   AC_PROG_RANLIB
  2262. ***************
  2263. *** 89,94 ****
  2264. --- 89,95 ----
  2265.           for i in $dirs ; do
  2266.           if test -r $i/X11/Intrinsic.h; then
  2267.               XINCLUDES=" -I$i"
  2268. +         break
  2269.           fi
  2270.           done
  2271.       fi
  2272. ***************
  2273. *** 112,117 ****
  2274. --- 113,119 ----
  2275.       for i in $dirs ; do
  2276.           if test -r $i/libX11.a; then
  2277.           XLIBSW="-L$i -lX11"
  2278. +         break
  2279.           fi
  2280.       done
  2281.       fi
  2282. *** ../tk4.0p2/./library/dialog.tcl    Fri Jul 28 09:35:56 1995
  2283. --- ./library/dialog.tcl    Fri Nov 24 15:03:00 1995
  2284. ***************
  2285. *** 3,9 ****
  2286.   # This file defines the procedure tk_dialog, which creates a dialog
  2287.   # box containing a bitmap, a message, and one or more buttons.
  2288.   #
  2289. ! # @(#) dialog.tcl 1.16 95/07/28 09:35:57
  2290.   #
  2291.   # Copyright (c) 1992-1993 The Regents of the University of California.
  2292.   # Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2293. --- 3,9 ----
  2294.   # This file defines the procedure tk_dialog, which creates a dialog
  2295.   # box containing a bitmap, a message, and one or more buttons.
  2296.   #
  2297. ! # @(#) dialog.tcl 1.18 95/11/24 15:03:04
  2298.   #
  2299.   # Copyright (c) 1992-1993 The Regents of the University of California.
  2300.   # Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2301. ***************
  2302. *** 45,53 ****
  2303.       frame $w.bot -relief raised -bd 1
  2304.       pack $w.bot -side bottom -fill both
  2305.   
  2306. !     # 2. Fill the top part with bitmap and message.
  2307.   
  2308. !     label $w.msg -wraplength 3i -justify left -text $text \
  2309.           -font -Adobe-Times-Medium-R-Normal--*-180-*-*-*-*-*-*
  2310.       pack $w.msg -in $w.top -side right -expand 1 -fill both -padx 3m -pady 3m
  2311.       if {$bitmap != ""} {
  2312. --- 45,56 ----
  2313.       frame $w.bot -relief raised -bd 1
  2314.       pack $w.bot -side bottom -fill both
  2315.   
  2316. !     # 2. Fill the top part with bitmap and message (use the option
  2317. !     # database for -wraplength so that it can be overridden by
  2318. !     # the caller).
  2319.   
  2320. !     option add *Dialog.msg.wrapLength 3i widgetDefault
  2321. !     label $w.msg -justify left -text $text \
  2322.           -font -Adobe-Times-Medium-R-Normal--*-180-*-*-*-*-*-*
  2323.       pack $w.msg -in $w.top -side right -expand 1 -fill both -padx 3m -pady 3m
  2324.       if {$bitmap != ""} {
  2325. ***************
  2326. *** 65,71 ****
  2327.           raise $w.button$i $w.default
  2328.           pack $w.default -in $w.bot -side left -expand 1 -padx 3m -pady 2m
  2329.           pack $w.button$i -in $w.default -padx 2m -pady 2m
  2330. -         bind $w <Return> "$w.button$i flash; set tkPriv(button) $i"
  2331.       } else {
  2332.           pack $w.button$i -in $w.bot -side left -expand 1 \
  2333.               -padx 3m -pady 2m
  2334. --- 68,73 ----
  2335. *** ../tk4.0p2/./library/focus.tcl    Thu Jun  8 13:18:30 1995
  2336. --- ./library/focus.tcl    Mon Oct 30 08:08:24 1995
  2337. ***************
  2338. *** 3,9 ****
  2339.   # This file defines several procedures for managing the input
  2340.   # focus.
  2341.   #
  2342. ! # @(#) focus.tcl 1.14 95/05/04 13:31:48
  2343.   #
  2344.   # Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2345.   #
  2346. --- 3,9 ----
  2347.   # This file defines several procedures for managing the input
  2348.   # focus.
  2349.   #
  2350. ! # @(#) focus.tcl 1.15 95/10/30 08:08:27
  2351.   #
  2352.   # Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2353.   #
  2354. ***************
  2355. *** 167,173 ****
  2356.       set script {
  2357.       if {("%d" == "NotifyAncestor") || ("%d" == "NotifyNonlinear")
  2358.           || ("%d" == "NotifyInferior")} {
  2359. !         focus %W
  2360.       }
  2361.       }
  2362.       if {$old != ""} {
  2363. --- 167,175 ----
  2364.       set script {
  2365.       if {("%d" == "NotifyAncestor") || ("%d" == "NotifyNonlinear")
  2366.           || ("%d" == "NotifyInferior")} {
  2367. !         if [tkFocusOK %W] {
  2368. !         focus %W
  2369. !         }
  2370.       }
  2371.       }
  2372.       if {$old != ""} {
  2373. *** ../tk4.0p2/./library/listbox.tcl    Tue Aug 22 08:49:49 1995
  2374. --- ./library/listbox.tcl    Thu Nov  2 11:02:17 1995
  2375. ***************
  2376. *** 3,9 ****
  2377.   # This file defines the default bindings for Tk listbox widgets
  2378.   # and provides procedures that help in implementing those bindings.
  2379.   #
  2380. ! # @(#) listbox.tcl 1.13 95/08/22 08:49:50
  2381.   #
  2382.   # Copyright (c) 1994 The Regents of the University of California.
  2383.   # Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2384. --- 3,9 ----
  2385.   # This file defines the default bindings for Tk listbox widgets
  2386.   # and provides procedures that help in implementing those bindings.
  2387.   #
  2388. ! # @(#) listbox.tcl 1.14 95/11/02 11:02:19
  2389.   #
  2390.   # Copyright (c) 1994 The Regents of the University of California.
  2391.   # Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2392. ***************
  2393. *** 37,42 ****
  2394. --- 37,51 ----
  2395.       tkListboxBeginSelect %W [%W index @%x,%y]
  2396.       }
  2397.   }
  2398. + # Ignore double clicks so that users can define their own behaviors.
  2399. + # Among other things, this prevents errors if the user deletes the
  2400. + # listbox on a double click.
  2401. + bind Listbox <2> {
  2402. +     # Empty script
  2403. + }
  2404.   bind Listbox <B1-Motion> {
  2405.       set tkPriv(x) %x
  2406.       set tkPriv(y) %y
  2407. *** ../tk4.0p2/./library/menu.tcl    Tue Aug 29 17:33:54 1995
  2408. --- ./library/menu.tcl    Fri Nov 24 14:51:33 1995
  2409. ***************
  2410. *** 4,10 ****
  2411.   # It also implements keyboard traversal of menus and implements a few
  2412.   # other utility procedures related to menus.
  2413.   #
  2414. ! # @(#) menu.tcl 1.54 95/08/29 17:33:53
  2415.   #
  2416.   # Copyright (c) 1992-1994 The Regents of the University of California.
  2417.   # Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2418. --- 4,10 ----
  2419.   # It also implements keyboard traversal of menus and implements a few
  2420.   # other utility procedures related to menus.
  2421.   #
  2422. ! # @(#) menu.tcl 1.59 95/11/24 14:51:37
  2423.   #
  2424.   # Copyright (c) 1992-1994 The Regents of the University of California.
  2425.   # Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2426. ***************
  2427. *** 102,112 ****
  2428.   
  2429.   # Must set focus when mouse enters a menu, in order to allow
  2430.   # mixed-mode processing using both the mouse and the keyboard.
  2431.   
  2432.   bind Menu <FocusIn> {}
  2433.   bind Menu <Enter> {
  2434.       set tkPriv(window) %W
  2435. !     focus %W
  2436.   }
  2437.   bind Menu <Leave> {
  2438.       tkMenuLeave %W %X %Y %s
  2439. --- 102,118 ----
  2440.   
  2441.   # Must set focus when mouse enters a menu, in order to allow
  2442.   # mixed-mode processing using both the mouse and the keyboard.
  2443. + # Don't set the focus if the event comes from a grab release,
  2444. + # though:  such an event can happen after as part of unposting
  2445. + # a cascaded chain of menus, after the focus has already been
  2446. + # restored to wherever it was before menu selection started.
  2447.   
  2448.   bind Menu <FocusIn> {}
  2449.   bind Menu <Enter> {
  2450.       set tkPriv(window) %W
  2451. !     if {"%m" != "NotifyUngrab"} {
  2452. !     focus %W
  2453. !     }
  2454.   }
  2455.   bind Menu <Leave> {
  2456.       tkMenuLeave %W %X %Y %s
  2457. ***************
  2458. *** 118,130 ****
  2459.       tkMenuButtonDown %W
  2460.   }
  2461.   bind Menu <ButtonRelease> {
  2462. !     tkMenuInvoke %W
  2463.   }
  2464.   bind Menu <space> {
  2465. !     tkMenuInvoke %W
  2466.   }
  2467.   bind Menu <Return> {
  2468. !     tkMenuInvoke %W
  2469.   }
  2470.   bind Menu <Escape> {
  2471.       tkMenuEscape %W
  2472. --- 124,136 ----
  2473.       tkMenuButtonDown %W
  2474.   }
  2475.   bind Menu <ButtonRelease> {
  2476. !     tkMenuInvoke %W 1
  2477.   }
  2478.   bind Menu <space> {
  2479. !     tkMenuInvoke %W 0
  2480.   }
  2481.   bind Menu <Return> {
  2482. !     tkMenuInvoke %W 0
  2483.   }
  2484.   bind Menu <Escape> {
  2485.       tkMenuEscape %W
  2486. ***************
  2487. *** 479,486 ****
  2488.   #
  2489.   # Arguments:
  2490.   # w -            Name of the menu widget.
  2491.   
  2492. ! proc tkMenuInvoke w {
  2493.       if {[$w type active] == "cascade"} {
  2494.       $w postcascade active
  2495.       set menu [$w entrycget active -menu]
  2496. --- 485,506 ----
  2497.   #
  2498.   # Arguments:
  2499.   # w -            Name of the menu widget.
  2500. + # buttonRelease -    1 means this procedure is called because of
  2501. + #            a button release;  0 means because of keystroke.
  2502.   
  2503. ! proc tkMenuInvoke {w buttonRelease} {
  2504. !     global tkPriv
  2505. !     if {$buttonRelease && ($tkPriv(window) == "")} {
  2506. !     # Mouse was pressed over a menu without a menu button, then
  2507. !     # dragged off the menu (possibly with a cascade posted) and
  2508. !     # released.  Unpost everything and quit.
  2509. !     $w postcascade none
  2510. !     $w activate none
  2511. !     tkMenuUnpost $w
  2512. !     return
  2513. !     }
  2514.       if {[$w type active] == "cascade"} {
  2515.       $w postcascade active
  2516.       set menu [$w entrycget active -menu]
  2517. ***************
  2518. *** 599,604 ****
  2519. --- 619,625 ----
  2520.       return
  2521.       }
  2522.       set length [expr [$menu index last]+1]
  2523. +     set quitAfter $length
  2524.       set active [$menu index active]
  2525.       if {$active == "none"} {
  2526.       set i 0
  2527. ***************
  2528. *** 606,611 ****
  2529. --- 627,638 ----
  2530.       set i [expr $active + $count]
  2531.       }
  2532.       while 1 {
  2533. +     if {$quitAfter <= 0} {
  2534. +         # We've tried every entry in the menu.  Either there are
  2535. +         # none, or they're all disabled.  Just give up.
  2536. +         return
  2537. +     }
  2538.       while {$i < 0} {
  2539.           incr i $length
  2540.       }
  2541. ***************
  2542. *** 621,626 ****
  2543. --- 648,654 ----
  2544.           return
  2545.       }
  2546.       incr i $count
  2547. +     incr quitAfter -1
  2548.       }
  2549.       $menu activate $i
  2550.       $menu postcascade $i
  2551. *** ../tk4.0p2/./library/prolog.ps    Thu Jun  8 13:18:31 1995
  2552. --- ./library/prolog.ps    Thu Nov  9 11:35:02 1995
  2553. ***************
  2554. *** 3,9 ****
  2555.   
  2556.   % This is a standard prolog for Postscript generated by Tk's canvas
  2557.   % widget.
  2558. ! % @(#) prolog.ps 1.2 94/12/09 10:53:18
  2559.   
  2560.   % The definitions below just define all of the variables used in
  2561.   % any of the procedures here.  This is needed for obscure reasons
  2562. --- 3,9 ----
  2563.   
  2564.   % This is a standard prolog for Postscript generated by Tk's canvas
  2565.   % widget.
  2566. ! % @(#) prolog.ps 1.3 95/11/09 11:35:04
  2567.   
  2568.   % The definitions below just define all of the variables used in
  2569.   % any of the procedures here.  This is needed for obscure reasons
  2570. ***************
  2571. *** 71,82 ****
  2572.       ] def
  2573.   } if
  2574.   
  2575. ! % Override the setfont procedure with a new procedure that re-encodes
  2576. ! % the font to use the ISO Latin-1 style.  The body of this procedure
  2577. ! % comes from Section 5.6.1 of the Postscript book.
  2578.   
  2579. ! /realsetfont /setfont load def
  2580. ! /setfont {
  2581.       dup length dict begin
  2582.       {1 index /FID ne {def} {pop pop} ifelse} forall
  2583.       /Encoding ISOLatin1Encoding def
  2584. --- 71,83 ----
  2585.       ] def
  2586.   } if
  2587.   
  2588. ! % font ISOEncode font
  2589. ! % This procedure changes the encoding of a font from the default
  2590. ! % Postscript encoding to ISOLatin1.  It's typically invoked just
  2591. ! % before invoking "setfont".  The body of this procedure comes from
  2592. ! % Section 5.6.1 of the Postscript book.
  2593.   
  2594. ! /ISOEncode {
  2595.       dup length dict begin
  2596.       {1 index /FID ne {def} {pop pop} ifelse} forall
  2597.       /Encoding ISOLatin1Encoding def
  2598. ***************
  2599. *** 88,94 ****
  2600.       % for the font.
  2601.   
  2602.       /Temporary exch definefont
  2603. -     realsetfont
  2604.   } bind def
  2605.   
  2606.   % StrokeClip
  2607. --- 89,94 ----
  2608. *** ../tk4.0p2/./doc/canvas.n    Wed Jun 28 16:29:59 1995
  2609. --- ./doc/canvas.n    Sat Oct 28 14:36:07 1995
  2610. ***************
  2611. *** 5,11 ****
  2612.   '\" See the file "license.terms" for information on usage and redistribution
  2613.   '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  2614.   '\" 
  2615. ! '\" @(#) canvas.n 1.39 95/06/28 16:29:58
  2616.   '\"
  2617.   .so man.macros
  2618.   .TH canvas n 4.0 Tk "Tk Built-In Commands"
  2619. --- 5,11 ----
  2620.   '\" See the file "license.terms" for information on usage and redistribution
  2621.   '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  2622.   '\" 
  2623. ! '\" @(#) canvas.n 1.40 95/10/28 14:36:10
  2624.   '\"
  2625.   .so man.macros
  2626.   .TH canvas n 4.0 Tk "Tk Built-In Commands"
  2627. ***************
  2628. *** 709,715 ****
  2629.   or \fBp\fR or nothing for printer's points (1/72 inch).
  2630.   Defaults to the height of the printed area on the screen.
  2631.   If both \fB\-pageheight\fR and \fB\-pagewidth\fR are specified then
  2632. ! the scale factor from the later option is used (non-uniform scaling
  2633.   is not implemented).
  2634.   .TP
  2635.   \fB\-pagewidth \fIsize\fR
  2636. --- 709,715 ----
  2637.   or \fBp\fR or nothing for printer's points (1/72 inch).
  2638.   Defaults to the height of the printed area on the screen.
  2639.   If both \fB\-pageheight\fR and \fB\-pagewidth\fR are specified then
  2640. ! the scale factor from \fB\-pagewidth\fR is used (non-uniform scaling
  2641.   is not implemented).
  2642.   .TP
  2643.   \fB\-pagewidth \fIsize\fR
  2644. ***************
  2645. *** 718,724 ****
  2646.   \fISize\fR has the same form as for \fB\-pageheight\fR.
  2647.   Defaults to the width of the printed area on the screen.
  2648.   If both \fB\-pageheight\fR and \fB\-pagewidth\fR are specified then
  2649. ! the scale factor from the later option is used (non-uniform scaling
  2650.   is not implemented).
  2651.   .TP
  2652.   \fB\-pagex \fIposition\fR
  2653. --- 718,724 ----
  2654.   \fISize\fR has the same form as for \fB\-pageheight\fR.
  2655.   Defaults to the width of the printed area on the screen.
  2656.   If both \fB\-pageheight\fR and \fB\-pagewidth\fR are specified then
  2657. ! the scale factor from \fB\-pagewidth\fR  is used (non-uniform scaling
  2658.   is not implemented).
  2659.   .TP
  2660.   \fB\-pagex \fIposition\fR
  2661. *** ../tk4.0p2/./doc/wish.1    Wed Jun  7 21:15:51 1995
  2662. --- ./doc/wish.1    Mon Sep 25 14:38:11 1995
  2663. ***************
  2664. *** 1,11 ****
  2665.   '\"
  2666.   '\" Copyright (c) 1991-1994 The Regents of the University of California.
  2667. ! '\" Copyright (c) 1994 Sun Microsystems, Inc.
  2668.   '\"
  2669.   '\" See the file "license.terms" for information on usage and redistribution
  2670.   '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  2671.   '\" 
  2672. ! '\" @(#) wish.1 1.19 95/06/07 21:15:41
  2673.   '\" 
  2674.   .so man.macros
  2675.   .TH wish 1 4.0 Tk "Tk Applications"
  2676. --- 1,11 ----
  2677.   '\"
  2678.   '\" Copyright (c) 1991-1994 The Regents of the University of California.
  2679. ! '\" Copyright (c) 1994-1995 Sun Microsystems, Inc.
  2680.   '\"
  2681.   '\" See the file "license.terms" for information on usage and redistribution
  2682.   '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  2683.   '\" 
  2684. ! '\" @(#) wish.1 1.20 95/09/25 14:38:12
  2685.   '\" 
  2686.   .so man.macros
  2687.   .TH wish 1 4.0 Tk "Tk Applications"
  2688. ***************
  2689. *** 29,34 ****
  2690. --- 29,39 ----
  2691.   Execute all X server commands synchronously, so that errors
  2692.   are reported immediately.  This will result in much slower
  2693.   execution, but it is useful for debugging.
  2694. + .IP "\fB\-\|\-\fR" 20
  2695. + Pass all remaining arguments through to the script's \fBargv\fR
  2696. + variable without interpreting them.
  2697. + This provides a mechanism for passing arguments such as \fB\-name\fR
  2698. + to a script instead of having \fBwish\fR interpret them.
  2699.   .BE
  2700.   
  2701.   .SH DESCRIPTION
  2702. ***************
  2703. *** 91,99 ****
  2704.   not including the options described above.
  2705.   .TP 15
  2706.   \fBargv\fR
  2707. ! Contains a Tcl list whose elements are the \fIarg\fR arguments (not
  2708. ! including the options described above), in order, or an empty string
  2709. ! if there are no \fIarg\fR arguments.
  2710.   .TP 15
  2711.   \fBargv0\fR
  2712.   Contains \fIfileName\fR if it was specified.
  2713. --- 96,105 ----
  2714.   not including the options described above.
  2715.   .TP 15
  2716.   \fBargv\fR
  2717. ! Contains a Tcl list whose elements are the \fIarg\fR arguments
  2718. ! that follow a \fB\-\|\-\fR option or don't match any of the
  2719. ! options described in OPTIONS above, in order, or an empty string
  2720. ! if there are no such arguments.
  2721.   .TP 15
  2722.   \fBargv0\fR
  2723.   Contains \fIfileName\fR if it was specified.
  2724. *** ../tk4.0p2/./tests/geometry.test    Tue Feb 21 16:36:58 1995
  2725. --- ./tests/geometry.test    Mon Nov 27 13:19:36 1995
  2726. ***************
  2727. *** 8,14 ****
  2728.   # See the file "license.terms" for information on usage and redistribution
  2729.   # of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  2730.   #
  2731. ! # @(#) geometry.test 1.5 95/02/21 16:36:58
  2732.   
  2733.   if {[info procs test] != "test"} {
  2734.       source defs
  2735. --- 8,14 ----
  2736.   # See the file "license.terms" for information on usage and redistribution
  2737.   # of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  2738.   #
  2739. ! # @(#) geometry.test 1.6 95/11/27 13:19:40
  2740.   
  2741.   if {[info procs test] != "test"} {
  2742.       source defs
  2743. ***************
  2744. *** 244,249 ****
  2745. --- 244,250 ----
  2746.       after 500 {set x 1}
  2747.       tkwait variable x
  2748.       wm deiconify .t
  2749. +     update
  2750.       winfo ismapped .t.quit
  2751.   } {1}
  2752.   catch {destroy .t}
  2753. *** ../tk4.0p2/./tests/textDisp.test    Wed Jun 28 14:52:05 1995
  2754. --- ./tests/textDisp.test    Mon Nov 27 13:22:03 1995
  2755. ***************
  2756. *** 7,13 ****
  2757.   # See the file "license.terms" for information on usage and redistribution
  2758.   # of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  2759.   #
  2760. ! # @(#) textDisp.test 1.31 95/06/28 14:52:03
  2761.   
  2762.   if {[string compare test [info procs test]] == 1} then \
  2763.     {source defs}
  2764. --- 7,13 ----
  2765.   # See the file "license.terms" for information on usage and redistribution
  2766.   # of this file, and for a DISCLAIMER OF ALL WARRANTIES.
  2767.   #
  2768. ! # @(#) textDisp.test 1.32 95/11/27 13:22:07
  2769.   
  2770.   if {[string compare test [info procs test]] == 1} then \
  2771.     {source defs}
  2772. ***************
  2773. *** 1410,1416 ****
  2774.       .t insert end "xxxx xxxxxxxxx xxxxxxxxxxxxx"
  2775.       .t xview moveto .3
  2776.       .t xview
  2777. ! } {0.285714 0.642857}
  2778.   test textDisp-14.8 {TkTextXviewCmd procedure} {
  2779.       .t delete 1.0 end
  2780.       .t insert end xxxxxxxxx\n
  2781. --- 1410,1416 ----
  2782.       .t insert end "xxxx xxxxxxxxx xxxxxxxxxxxxx"
  2783.       .t xview moveto .3
  2784.       .t xview
  2785. ! } {0.303571 0.660714}
  2786.   test textDisp-14.8 {TkTextXviewCmd procedure} {
  2787.       .t delete 1.0 end
  2788.       .t insert end xxxxxxxxx\n
  2789.